android_kernel_xiaomi_sm7250/include
Lennart Poettering d7a76e4cb3 ACPI: consolidate functions in acpi ec driver
Unify the following functions:

    acpi_ec_poll_read()
    acpi_ec_poll_write()
    acpi_ec_poll_query()
    acpi_ec_intr_read()
    acpi_ec_intr_write()
    acpi_ec_intr_query()

into:

    acpi_ec_poll_transaction()
    acpi_ec_intr_transaction()

These new functions take as arguments an ACPI EC command, a few bytes
to write to the EC data register and a buffer for a few bytes to read
from the EC data register. The old _read(), _write(), _query() are
just special cases of these functions.

Then unified the code in acpi_ec_poll_transaction() and
acpi_ec_intr_transaction() a little more. Both functions are now just
wrappers around the new acpi_ec_transaction_unlocked() function. The
latter contains the EC access logic, the two original
function now just do their special way of locking and call the the
new function for the actual work.

This saves a lot of very similar code. The primary reason for doing
this, however, is that my driver for MSI 270 laptops needs to issue
some non-standard EC commands in a safe way. Due to this I added a new
exported function similar to ec_write()/ec_write() which is called
ec_transaction() and is essentially just a wrapper around
acpi_ec_{poll,intr}_transaction().

Signed-off-by: Lennart Poettering <mzxreary@0pointer.de>
Acked-by: Luming Yu <luming.yu@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Len Brown <len.brown@intel.com>
2006-10-14 00:49:52 -04:00
..
acpi ACPI: Allow setting SCI_EN bit in PM1_CONTROL register 2006-10-10 17:14:44 -07:00
asm-alpha [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-arm [PATCH] arm-versatile iomem annotations 2006-10-11 11:17:06 -07:00
asm-arm26 fix file specification in comments 2006-10-03 23:01:26 +02:00
asm-avr32 [PATCH] IRQ: Fix AVR32 breakage 2006-10-11 11:14:14 -07:00
asm-cris [PATCH] remove remaining errno and __KERNEL_SYSCALLS__ references 2006-10-02 07:57:23 -07:00
asm-frv [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-generic [PATCH] sched: likely profiling 2006-10-11 11:14:22 -07:00
asm-h8300 [PATCH] remove remaining errno and __KERNEL_SYSCALLS__ references 2006-10-02 07:57:23 -07:00
asm-i386 [VOYAGER] fix up ptregs removal mess 2006-10-12 22:25:03 -05:00
asm-ia64 [PATCH] ia64/sn __iomem annotations 2006-10-10 15:37:22 -07:00
asm-m32r [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-m68k [PATCH] m68k uaccess __user annotations 2006-10-11 11:17:06 -07:00
asm-m68knommu [PATCH] m68knommu: sync syscalls with m68k 2006-10-13 08:35:39 -07:00
asm-mips Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus 2006-10-11 15:30:14 -07:00
asm-parisc [PARISC] pdc_init no longer exists 2006-10-07 05:22:30 -06:00
asm-powerpc [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-ppc [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-s390 [S390] cio: Use ccw_dev_id and subchannel_id in ccw_device_private 2006-10-11 15:31:38 +02:00
asm-sh Merge master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6 2006-10-12 08:33:23 -07:00
asm-sh64 [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-sparc IRQ: Use the new typedef for interrupt handler function pointers 2006-10-09 12:19:47 +01:00
asm-sparc64 [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-um [PATCH] um: irq changes break build 2006-10-06 08:53:42 -07:00
asm-v850 [PATCH] remove remaining errno and __KERNEL_SYSCALLS__ references 2006-10-02 07:57:23 -07:00
asm-x86_64 [PATCH] Consolidate check_signature 2006-10-11 11:14:23 -07:00
asm-xtensa fix file specification in comments 2006-10-03 23:01:26 +02:00
crypto [CRYPTO] digest: Added user API for new hash type 2006-09-21 11:46:17 +10:00
keys
linux ACPI: consolidate functions in acpi ec driver 2006-10-14 00:49:52 -04:00
math-emu
media V4L/DVB (4666): Ensure the WM8775 driver is loaded generically for any board. 2006-10-03 15:13:48 -03:00
mtd Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 2006-10-01 17:55:53 +01:00
net [NET]: Introduce protocol-specific destructor for time-wait sockets. 2006-10-12 00:00:00 -07:00
pcmcia
rdma IB/sa: fix ib_sa_selector names 2006-09-22 15:22:55 -07:00
rxrpc
scsi Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2006-10-04 18:57:35 -07:00
sound [ALSA] version 1.0.13 2006-10-06 20:28:26 +02:00
video fix file specification in comments 2006-10-03 23:01:26 +02:00
Kbuild [HEADERS] One line per header in Kbuild files to reduce conflicts 2006-09-19 12:43:58 +01:00