summaryrefslogtreecommitdiffstats
path: root/drivers/misc/mei
Commit message (Collapse)AuthorAgeFilesLines
* mei: me: move probe quirk to cfg structureTomas Winkler2014-05-274-34/+54
| | | | | | | | Move quirk FW type detector to cfg structure Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: add per device configurationAlexander Usyskin2014-05-278-52/+144
| | | | | | | | | | Add mei_cfg structure that holds per device configuration data and hooks, as the first step we add firmware status register offsets Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: read H_CSR after asserting resetTomas Winkler2014-05-271-0/+12
| | | | | | | | | | | According the spec the host should read H_CSR again after asserting reset H_RST to ensure that reset was read by the firmware Cc: stable@vger.kernel.org Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: drop harmful wait optimizationTomas Winkler2014-05-271-3/+1
| | | | | | | | | | It my take time till ME_RDY will be cleared after the reset, so we cannot check the bit before we got the interrupt Cc: stable@vger.kernel.org Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: fix hw ready reset flowTomas Winkler2014-05-271-3/+6
| | | | | | | | | | | | We cleared H_RST for H_CSR on spurious interrupt generated when ME_RDY while cleared and not while ME_RDY is set. The spurious interrupt is not delivered on all platforms in this case the driver may fail to initialize. Cc: stable@vger.kernel.org Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: fix memory leak of mei_clients arrayTomas Winkler2014-05-273-18/+31
| | | | | | | | | we never freed the mei_clients array on driver shutdown only on reset add mei_hbm_reset function that wraps the hbm cleanup Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: set connecting state just upon connection request is sent to the fwAlexander Usyskin2014-05-035-7/+1
| | | | | | | | | | | | | | | | | | Adding power gating introduced new waiting state for client also during connection attempt, a connection request can be queued for later either due device is power gated or due to other on going connection. We setting client connection state before start of full connect procedure so in both cased the client state will be MEI_FILE_CONNECTING which create interlock between the two connection attempts, both detecting that another connection is in progress. The interlock is resolved by moving client to connecting state only upon connection request transmission, so the first cb in queue can be processed. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: make return values consistent across the driverAlexander Usyskin2014-05-032-4/+3
| | | | | | | | | | Follow-up for bits missed in commit 7ca96aa278f8b9983184e318b06a0ed9ad0297b8 mei: make return values consistent across the driver Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: extract fw status registersAlexander Usyskin2014-05-035-5/+127
| | | | | | | | | Fetch FW status registers, as they are important in in understanding of FW reset reasons Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: bump hbm version to 1.1 to support power gatingTomas Winkler2014-05-031-1/+1
| | | | | | | | Communicate hbm version 1.1 to firmware to tell that we now support power gating isolation protocol Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: txe: use runtime PG pm domain for non wakeable devicesAlexander Usyskin2014-05-031-0/+49
| | | | | | | | | | | For non wakeable devices we can't use pci runtime framework as we are not able to wakeup from D3 states. Instead we create new pg runtime domain that only drives TXE power gating protocol to reduce the power consumption. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: use runtime PG pm domain for non wakeable devicesTomas Winkler2014-05-032-0/+53
| | | | | | | | | | | For non wakeable devices we can't use pci runtime framework as we are not able to wakeup from D3 states. Instead we create new pg runtime domain that only drives ME power gating protocol to reduce the power consumption. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: use runtime pm in write and read flowTomas Winkler2014-05-031-13/+71
| | | | | | | | | | Take rpm token on operation start to initiate rpm resume if needed. Mark last busy time, release token and advice rpm framework to try to autosuspend on operation end. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: txe: add runtime pm frameworkAlexander Usyskin2014-05-032-4/+99
| | | | | | | | | | Add runtime pm framework for TXE devices. The runtime pm handlers are used to run txe power gating isolation protocol. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: add runtime pm frameworkTomas Winkler2014-05-033-2/+100
| | | | | | | | | | Add runtime pm framework for ME devices. The runtime pm handlers are used to run me power gating isolation protocol Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: add function to check write queuesTomas Winkler2014-05-032-0/+23
| | | | | | | | | The driver needs to check whether the write queue idle before entering power gating Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: add pg exit and entry flow commandsTomas Winkler2014-05-034-4/+95
| | | | | | | | | | | | | | | | For power gating entry we write hbm pg entry request command and then we set pg register For power gating exit we clear pg register and wait for exit request hbm command. Exit power gating request might also be initiated by the firmware w/o explicit driver request The power gating state is tracked by pg_state member of me_hw Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: expose hardware power gating state to mei layerTomas Winkler2014-05-035-19/+93
| | | | | | | | | | | | | | | | | | Since the runtime pm and the internal power gating cannot be in complete sync in regards to I/O operations, we need to expose the device hardware internal power gating state to mei layer 2. We add pg_state handler that translate the hw internal pg state to mei layer 2. We add power gating event variable to keep power track of power gating transitions Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Reviewed-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: condition PGI support on HW and HBM versionTomas Winkler2014-05-034-0/+67
| | | | | | | | | | | | | Enable power gating isolation only if hw and fw support it. This is indicated by ME_PGIC_HRA bit in ME_CSR_HA register and on HBM protocol version. The information is exported to MEI layer through new pg_is_enabled hw op. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: add power gating isolation register write wrappersTomas Winkler2014-05-031-0/+29
| | | | | | | | | Add entry and exit power gating isolation register write handler. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: introduce power gating registersTomas Winkler2014-05-031-0/+9
| | | | | | | | LPT devices have internal power gating handled through registers and hbm calls Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: implement power gating isolation hbm layerTomas Winkler2014-05-035-0/+60
| | | | | | | | | | | | Add send message functions and receive dispatch stubs for power gating isolation hbm protocol. The protocol consist of requests for entering and exiting the power gating isolation state and their responses. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: ignore client writing state during cb completionAlexander Usyskin2014-04-162-4/+2
| | | | | | | | | | | | | | | | | | Ignore client writing state during cb completion to fix a memory leak. When moving cbs to the completion list we should not look at writing_state as this state can be already overwritten by next write, the fact that a cb is on the write waiting list means that it was already written to the HW and we can safely complete it. Same pays for wait in poll handler, we do not have to check the state wake is done after completion list processing. Cc: stable@vger.kernel.org Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* mei: me: do not load the driver if the FW doesn't support MEI interfaceTomas Winkler2014-04-162-7/+28
| | | | | | | | | | | | | | | | | | NM and SPS FW types that may run on ME device on server platforms do not have valid MEI/HECI interface and driver should not be bound to it as this might lead to system hung. In practice not all BIOSes effectively hide such devices from the OS and in some cases it is not possible. We determine FW type by examining Host FW status registers in order to unbind the driver. In this patch we are adding check for ME on Cougar Point, Lynx Point Devices Cc: stable <stable@vger.kernel.org> # 3.10+ Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Tested-by: Nikola Ciprich <nikola.ciprich@linuxbox.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Merge tag 'char-misc-3.15-rc1' of ↵Linus Torvalds2014-04-0122-550/+2485
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc Pull char/misc driver patches from Greg KH: "Here's the big char/misc driver updates for 3.15-rc1. Lots of various things here, including the new mcb driver subsystem. All of these have been in linux-next for a while" * tag 'char-misc-3.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (118 commits) extcon: Move OF helper function to extcon core and change function name extcon: of: Remove unnecessary function call by using the name of device_node extcon: gpio: Use SIMPLE_DEV_PM_OPS macro extcon: palmas: Use SIMPLE_DEV_PM_OPS macro mei: don't use deprecated DEFINE_PCI_DEVICE_TABLE macro mei: amthif: fix checkpatch error mei: client.h fix checkpatch errors mei: use cl_dbg where appropriate mei: fix Unnecessary space after function pointer name mei: report consistently copy_from/to_user failures mei: drop pr_fmt macros mei: make me hw headers private to me hw. mei: fix memory leak of pending write cb objects mei: me: do not reset when less than expected data is received drivers: mcb: Fix build error discovered by 0-day bot cs5535-mfgpt: Simplify dependencies spmi: pm: drop bus-level PM suspend/resume routines spmi: pmic_arb: make selectable on ARCH_QCOM Drivers: hv: vmbus: Increase the limit on the number of pfns we can handle pch_phub: Report error writing MAC back to user ...
| * mei: don't use deprecated DEFINE_PCI_DEVICE_TABLE macroTomas Winkler2014-03-172-2/+2
| | | | | | | | | | | | | | | | Using struct pci_device_id is preferred over deprecated DEFINE_PCI_DEVICE_TABLE macro Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: amthif: fix checkpatch errorTomas Winkler2014-03-171-2/+1
| | | | | | | | | | | | | | | | | | ERROR: else should follow close brace '}' + } + else { Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: client.h fix checkpatch errorsTomas Winkler2014-03-171-4/+4
| | | | | | | | | | | | | | | | Fix checkpatch error return is not a function, parentheses are not required Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: use cl_dbg where appropriateTomas Winkler2014-03-172-10/+3
| | | | | | | | | | | | | | | | | | | | use cl_dbg for debug log messages in cl context this also removes checkpatch warning: quoted string split across lines Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: fix Unnecessary space after function pointer nameTomas Winkler2014-03-171-12/+12
| | | | | | | | | | | | | | | | Fix checkpatch warining: Unnecessary space after function pointer name Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: report consistently copy_from/to_user failuresAlexander Usyskin2014-03-172-3/+6
| | | | | | | | | | | | | | | | | | Consistently display error on possible copy_from/to_user failures use dev_dbg so it cannot be abused to flood the kernel log Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: drop pr_fmt macrosTomas Winkler2014-03-172-6/+0
| | | | | | | | | | | | | | | | we are using dev_ logging facility so we don't need pr_fmt macros Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Reviewed-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: make me hw headers private to me hw.Tomas Winkler2014-03-179-10/+4
| | | | | | | | | | | | | | | | | | Remove includes of me-hw.h and me-hw-regs.h headers from the mei generic code. The mei layer should not depend on hw specific headers Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: fix memory leak of pending write cb objectsTomas Winkler2014-03-172-39/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Write callbacks are released on the write completed path but when file handler is closed before the writes are completed those are left dangling on write and write_waiting queues. We add mei_io_list_free function to perform this task Also move static functions to client.c form client.h Cc: stable <stable@vger.kernel.org> # 3.11+ Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: me: do not reset when less than expected data is receivedTomas Winkler2014-03-172-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is a race in ME hardware between data copy for host and interrupt delivery. An interrupt can be delivered prior to whole data copied for the host to read but rather then going trough the reset we just merely need to wait for the next interrupt. The bug is visible in read/write stress with multiple connections per client This is a regression caused as a side effect of the commit: commit 544f94601409653f07ae6e22d4a39e3a90dceead mei: do not run reset flow from the interrupt thread Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Cc: stable <stable@vger.kernel.org> # 3.14 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: fix regressions caused by removing ext_msgAlexander Usyskin2014-03-081-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Delete cb from list before freeing it 2. Fix missed break that leads to switch case fall-through and BUG invocation. Regression from: commit 6bb948c9e500d24321c36c67c81daf8d1a7e561e mei: get rid of ext_msg Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: wd: fix stop completion failureTomas Winkler2014-02-282-16/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While running Documentation/watchdog/src/watchdog-simple.c and quiting by Ctrl-C, fallowing error is displayed: mei_me 0000:00:16.0: wd: stop failed to complete ret=-512. The whatchdog core framework is not able to propagate -ESYSRESTART or -EINTR. Also There is no much sense in restarting the close system call so instead of using wait_event_interruptible_timeout we can use wait_event_timeout with reasonable 10 msecs timeout. Reported-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: wd: simplify wd_send commandTomas Winkler2014-02-282-29/+30
| | | | | | | | | | | | | | | | | | Add reduce credits to wd_send to remove code repetition and simplify error handling Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: make return values consistent across the driverAlexander Usyskin2014-02-288-33/+33
| | | | | | | | | | | | | | | | | | | | | | | | 1. Propagate ENOTTY to user space if the client is not present in the system 2. Use ETIME consistently on timeouts 3. Return EIO on write failures 4. Return ENODEV on recoverable device failures such as resets Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: revamp writing slot countingTomas Winkler2014-02-288-80/+68
| | | | | | | | | | | | | | | | | | | | Since txe use doorbell and not circular buffer we have to cheat in write slot counting, txe always consume all the slots upon write. In order for it to work we need to track slots using mei_hbuf_empty_slots() instead of tracking it in mei layer Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: add mei_hbuf_acquire wrapperTomas Winkler2014-02-287-47/+57
| | | | | | | | | | | | | | | | | | | | | | | | A client has to acquire host buffer before writing, we add lock like wrapper to replace the code snippet if (dev->hbuf_is_ready) dev->hbuf_is_ready = false; Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * mei: txe: include irqreturn.h for irqreturn_t etcStephen Rothwell2014-02-282-0/+3
| | | | | | | | | | Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * Merge branch 'char-misc-linus' into char-misc-nextGreg Kroah-Hartman2014-02-191-1/+3
| |\ | | | | | | | | | | | | | | | | | | We want the mei change here to allow future mei patches to apply properly. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: txe: put pm callbacks under PM_SLEEP ifdefTomas Winkler2014-02-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | PCI suspend resume callbacks should be defined under CONFIG_PM_SLEEP Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: me: put pm callbacks under PM_SLEEP ifdefAlexander Usyskin2014-02-181-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will eliminate compilation warning: drivers/misc/mei/pci-me.c:303:12: warning: mei_me_pci_suspend defined but not used [-Wunused-function] static int mei_me_pci_suspend(struct device *device) drivers/misc/mei/pci-me.c:323:12: warning: mei_me_pci_resume defined but not used [-Wunused-function] static int mei_me_pci_resume(struct device *device) Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: don't of list_for_each_entry_safe when not deletingTomas Winkler2014-02-185-33/+28
| | | | | | | | | | | | | | | | | | | | | | | | We can use simply list_for_each_entry if there is no entry removal Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: use helper function to find me client by idAlexander Usyskin2014-02-182-48/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | We already have a helper to find me client by id, let's use it in all relevant places. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: fix potential read outside of array boundsAlexander Usyskin2014-02-181-13/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Drop not-very-useful check and with this fix read on index that can be after array end. Cleanup search function as byproduct. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: wd and amthif use mei_cl_ api for dis/connectionTomas Winkler2014-02-185-80/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Connect wd and amthif through regular mei_cl_connect API as there is no reason to connect in asynchronous mode. Also use mei_cl_is_connected in order to protect flows instead of depending on wd_pending and amthif_timer Now we can remove all the special handling in hbm layer Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| * | mei: hbm: revamp client connect and disconnection statusAlexander Usyskin2014-02-184-39/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Return -ENOTTY on client connect if the requested client was not found on the enumeration list or the client was internally disabled, in the later case FW will return NOT_FOUND. 2. Return -EBUSY if the client cannot be connected because of resource contention 3. Change response status enum to have MEI_CL_ prefix 4. Add function to translate response status to a string for more readable logging Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
OpenPOWER on IntegriCloud