* [PATCH] HID: Kconfig updates for the Sony module
From: Frank Praznik @ 2014-02-01 15:39 UTC (permalink / raw)
To: linux-input; +Cc: jkosina, Frank Praznik
Update the HID_SONY config with 'select POWER_SUPPLY' to fix build issues
relating to undefined references to the power_supply_* functions in
certain build configurations.
Update the description text to reflect that Playstation 4 controllers are now
supported.
Signed-off-by: Frank Praznik <frank.praznik@oh.rr.com>
---
Apply to jikos/hid.git/for-3.15/sony
This should fix the errors that the buildbot was reporting.
drivers/hid/Kconfig | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/hid/Kconfig b/drivers/hid/Kconfig
index f722001..0e4cdc2 100644
--- a/drivers/hid/Kconfig
+++ b/drivers/hid/Kconfig
@@ -608,25 +608,27 @@ config HID_SAMSUNG
Support for Samsung InfraRed remote control or keyboards.
config HID_SONY
- tristate "Sony PS2/3 accessories"
+ tristate "Sony PS2/3/4 accessories"
depends on USB_HID
depends on NEW_LEDS
depends on LEDS_CLASS
+ select POWER_SUPPLY
---help---
Support for
* Sony PS3 6-axis controllers
+ * Sony PS4 DualShock 4 controllers
* Buzz controllers
* Sony PS3 Blue-ray Disk Remote Control (Bluetooth)
* Logitech Harmony adapter for Sony Playstation 3 (Bluetooth)
config SONY_FF
- bool "Sony PS2/3 accessories force feedback support"
+ bool "Sony PS2/3/4 accessories force feedback support"
depends on HID_SONY
select INPUT_FF_MEMLESS
---help---
- Say Y here if you have a Sony PS2/3 accessory and want to enable force
- feedback support for it.
+ Say Y here if you have a Sony PS2/3/4 accessory and want to enable
+ force feedback support for it.
config HID_SPEEDLINK
tristate "Speedlink VAD Cezanne mouse support"
--
1.8.5.3
^ permalink raw reply related
* Re: PROBLEM: Kernel-Panic when using Apple-Magic-Trackpad
From: Gerrit Addiks @ 2014-02-01 15:59 UTC (permalink / raw)
To: Jiri Kosina; +Cc: linux-input, David Herrmann, Gustavo F. Padovan
In-Reply-To: <alpine.LNX.2.00.1401301156090.31013@pobox.suse.cz>
Hello,
Thank you for showing me that patch. After a couple days of testing it i
can pretty clearly say that this patch fixes the kernel-panic for me. I
hope the patch finds it's way into the public kernel repository as soon
as possible.
I have compiled two kernels from the latest version (git: master), one
patched and one unpatched: While the patched version worked flawlessly
for days, the unpatched version got multiple times into kernel-panic
after just seconds.
Sincerely,
Gerrit Addiks
Am 30.01.2014 11:57, schrieb Jiri Kosina:
> On Wed, 29 Jan 2014, Gerrit Addiks wrote:
>
>> [1.] Kernel-Panic when using Apple-Magic-Trackpad
> [ some CCs added ]
>
> Could you please check whether patch from
>
> http://www.spinics.net/lists/linux-bluetooth/msg41725.html
>
> works around the issue for you?
>
> Thanks.
>
>> [2.] When the Linux-Kernel (>v3.11-rc1 in my case) gets used with the
>> Apple Magic Trackpad, it will Kernel-Panic in one of three ways:
>>
>> 1. Switch to text-based UI and 'display' the panic.
>> (Photos of that can be found in [7.9.])
>>
>> 2. Restore from the panic and dump all info from above into syslog.
>> I dont really know if that is really the same kernel-panic,
>> but it was triggered the exact same way and to my untrained eye it
>> looks related somehow. Also it just occoured just once and then
>> never again. The exact output frim syslog can be found in [7.8.]
>>
>> 3. Freeze the whole computer to the point where not even the
>> numpad-LED works.
>>
>> It does not matter what computer is used. I have reproduced this panic
>> on two very different computers (A MacMini5.1 and a Dell MidTower) and
>> two physical instances of the trackpad, so i strongly assume
>> that this is only about the software, not caused by hardware fault.
>>
>> I have reproduced this kernel-panic in many versions between [v3.11-rc1]
>> and [v3.13]. I have also done a git bisect (which has eaten up my whole
>> weekend) and after 13 long steps i could find the first bad commit:
>> [b1a1442a23776756b254b69786848a94d92445ba]
>> [HID: core: fix reporting of raw events]
>>
>> For those who dont know (or dont want to know):
>> The Apple Magic Trackpad is a wireless pointing (and gestures) device
>> that connects using bluetooth. It is like a big notebook trackpad as
>> an own device. The linux driver for that thing is synaptics.
>> (But from the first bad commit it looks like hid is at fault)
>>
>> This report is based on the launchpad-report #1269600:
>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1269600
>> A few photos of the kernel-panic in textmode as well as some more
>> info's can be found there.
>>
>> This report was created according to the following guide:
>> https://www.kernel.org/pub/linux/docs/lkml/reporting-bugs.html
>>
>> Because this is the first time for me to ever submit a report,
>> please do not think bad of me if i did something wrong.
>> I can be contacted via [gerrit@addiks.de] for any questions,
>> thank you for paying attention to this.
>>
>> [3.] trackpad, synaptics, bluetooth, kernel-panic
>>
>> [4.] /proc/version :
>> Linux version 3.13.0-031300-generic (apw@gomeisa)
>> (gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) )
>> #201401192235 SMP Mon Jan 20 03:36:48 UTC 2014
>>
>> (This is a mainline-kernel acquired from:
>> [http://kernel.ubuntu.com/~kernel-ppa/mainline/?C=N;O=D])
>>
>> [5.] I judge myself waaay too low-skilled to understand the oops-tracing.txt
>> in a short time, but i will try to understand it in the future.
>> I can just barely code C++ and have little to no internal knowledge about
>> the internal kernel.
>> Maybe someone can help me out here and tell me what to do, thanks.
>>
>> [6.] I think it is impossible to test this without an Apple-Magic-Trackpad.
>> But if you do have one: just connect it, use it a while and see the
>> kernel cry in agony. (You may need to watch the syslog in case the kernel
>> survives the panic and just reports about it). In rare cases it can took
>> a few hours of use until it breaks, but in the very most cases it breaks
>> very in the first minutes.
>>
>> [7.] Environment:
>>
>> The following information are collected while the trackpad is connected
>> and the linux version from [4.] is used and while the author (me) does
>> not dare to touch the trackpad to not cause another kernel-panic.
>>
>> [7.1.] ver_linux :
>>
>> If some fields are empty or look unusual you may have an old version.
>> Compare to the current minimal requirements in Documentation/Changes.
>>
>> Linux gerrit-testing-1404 3.13.0-031300-generic #201401192235 SMP Mon Jan 20
>> 03:36:48 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
>>
>> Gnu C 4.8
>> Gnu make 3.81
>> binutils 2.24
>> util-linux 2.20.1
>> mount support
>> module-init-tools 15
>> e2fsprogs 1.42.9
>> pcmciautils 018
>> PPP 2.4.5
>> Linux C Library 2.18
>> Dynamic linker (ldd) 2.18
>> Procps 3.3.9
>> Net-tools 1.60
>> Kbd 1.15.5
>> Sh-utils 8.21
>> wireless-tools 30
>> Modules Loaded parport_pc ppdev bnep rfcomm intel_rapl
>> x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel kvm b43
>> snd_hda_codec_hdmi snd_hda_codec_cirrus crct10dif_pclmul crc32_pclmul
>> ghash_clmulni_intel aesni_intel aes_x86_64 mac80211 lrw snd_hda_intel gf128mul
>> snd_hda_codec glue_helper snd_usb_audio i915 snd_usbmidi_lib ablk_helper
>> snd_hwdep cryptd cfg80211 snd_seq_midi btusb snd_seq_midi_event
>> hid_roccat_koneplus snd_rawmidi bluetooth hid_roccat snd_seq snd_pcm ssb
>> drm_kms_helper applesmc hid_roccat_common hid_appleir snd_seq_device
>> snd_page_alloc joydev drm input_polldev snd_timer microcode i2c_algo_bit snd
>> apple_gmux shpchp soundcore lpc_ich lp mei_me mei apple_bl parport bcma
>> mac_hid video hid_generic usbhid hid tg3 ptp firewire_ohci pps_core
>> firewire_core sdhci_pci crc_itu_t sdhci
>>
>> [7.2.] /proc/cpuinfo :
>>
>> processor : 0
>> vendor_id : GenuineIntel
>> cpu family : 6
>> model : 42
>> model name : Intel(R) Core(TM) i5-2415M CPU @ 2.30GHz
>> stepping : 7
>> microcode : 0x1a
>> cpu MHz : 1269.582
>> cache size : 3072 KB
>> physical id : 0
>> siblings : 4
>> core id : 0
>> cpu cores : 2
>> apicid : 0
>> initial apicid : 0
>> fpu : yes
>> fpu_exception : yes
>> cpuid level : 13
>> wp : yes
>> flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov
>> pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm
>> constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc
>> aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16
>> xtpr pdcm pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx
>> lahf_lm ida arat xsaveopt pln pts dtherm tpr_shadow vnmi flexpriority ept vpid
>> bogomips : 4589.28
>> clflush size : 64
>> cache_alignment : 64
>> address sizes : 36 bits physical, 48 bits virtual
>> power management:
>>
>> processor : 1
>> [... trimmed down, same as processor 0... ]
>>
>> processor : 2
>> [... trimmed down, same as processor 0... ]
>>
>> processor : 3
>> [... trimmed down, same as processor 0... ]
>>
>> [7.3.] /proc/modules :
>>
>> hid_magicmouse 13722 0 - Live 0x0000000000000000
>> hidp 24353 1 - Live 0x0000000000000000
>> parport_pc 36962 0 - Live 0x0000000000000000
>> ppdev 17711 0 - Live 0x0000000000000000
>> bnep 19884 2 - Live 0x0000000000000000
>> rfcomm 74748 12 - Live 0x0000000000000000
>> intel_rapl 19228 0 - Live 0x0000000000000000
>> x86_pkg_temp_thermal 14269 0 - Live 0x0000000000000000
>> intel_powerclamp 19031 0 - Live 0x0000000000000000
>> coretemp 17728 0 - Live 0x0000000000000000
>> kvm_intel 144426 0 - Live 0x0000000000000000
>> kvm 468147 1 kvm_intel, Live 0x0000000000000000
>> b43 397438 0 - Live 0x0000000000000000
>> snd_hda_codec_hdmi 46898 1 - Live 0x0000000000000000
>> snd_hda_codec_cirrus 18855 1 - Live 0x0000000000000000
>> crct10dif_pclmul 14250 0 - Live 0x0000000000000000
>> crc32_pclmul 13160 0 - Live 0x0000000000000000
>> ghash_clmulni_intel 13259 0 - Live 0x0000000000000000
>> aesni_intel 55720 0 - Live 0x0000000000000000
>> aes_x86_64 17131 1 aesni_intel, Live 0x0000000000000000
>> mac80211 654124 1 b43, Live 0x0000000000000000
>> lrw 13323 1 aesni_intel, Live 0x0000000000000000
>> snd_hda_intel 57222 3 - Live 0x0000000000000000
>> gf128mul 14951 1 lrw, Live 0x0000000000000000
>> snd_hda_codec 199156 3 snd_hda_codec_hdmi,snd_hda_codec_cirrus,snd_hda_intel,
>> Live 0x0000000000000000
>> glue_helper 14095 1 aesni_intel, Live 0x0000000000000000
>> snd_usb_audio 156119 3 - Live 0x0000000000000000
>> i915 816869 3 - Live 0x0000000000000000
>> snd_usbmidi_lib 29576 1 snd_usb_audio, Live 0x0000000000000000
>> ablk_helper 13597 1 aesni_intel, Live 0x0000000000000000
>> snd_hwdep 13613 2 snd_hda_codec,snd_usb_audio, Live 0x0000000000000000
>> cryptd 20530 3 ghash_clmulni_intel,aesni_intel,ablk_helper, Live
>> 0x0000000000000000
>> cfg80211 509407 2 b43,mac80211, Live 0x0000000000000000
>> snd_seq_midi 13324 0 - Live 0x0000000000000000
>> btusb 28326 0 - Live 0x0000000000000000
>> snd_seq_midi_event 14899 1 snd_seq_midi, Live 0x0000000000000000
>> hid_roccat_koneplus 15270 0 - Live 0x0000000000000000
>> snd_rawmidi 30465 2 snd_usbmidi_lib,snd_seq_midi, Live 0x0000000000000000
>> bluetooth 411140 27 hidp,bnep,rfcomm,btusb, Live 0x0000000000000000
>> hid_roccat 13485 1 hid_roccat_koneplus, Live 0x0000000000000000
>> snd_seq 66061 2 snd_seq_midi,snd_seq_midi_event, Live 0x0000000000000000
>> snd_pcm 107140 5 snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_usb_audio,
>> Live 0x0000000000000000
>> ssb 63241 1 b43, Live 0x0000000000000000
>> drm_kms_helper 53224 1 i915, Live 0x0000000000000000
>> applesmc 19564 0 - Live 0x0000000000000000
>> hid_roccat_common 13791 1 hid_roccat_koneplus, Live 0x0000000000000000
>> hid_appleir 13010 0 - Live 0x0000000000000000
>> snd_seq_device 14497 3 snd_seq_midi,snd_rawmidi,snd_seq, Live
>> 0x0000000000000000
>> snd_page_alloc 18798 2 snd_hda_intel,snd_pcm, Live 0x0000000000000000
>> joydev 17575 0 - Live 0x0000000000000000
>> drm 308397 4 i915,drm_kms_helper, Live 0x0000000000000000
>> input_polldev 13896 1 applesmc, Live 0x0000000000000000
>> snd_timer 30038 2 snd_seq,snd_pcm, Live 0x0000000000000000
>> microcode 23788 0 - Live 0x0000000000000000
>> i2c_algo_bit 13564 1 i915, Live 0x0000000000000000
>> snd 73850 24
>> snd_hda_codec_hdmi,snd_hda_codec_cirrus,snd_hda_intel,snd_hda_codec,snd_usb_audio,snd_usbmidi_lib,snd_hwdep,snd_seq_midi,snd_rawmidi,snd_seq,snd_pcm,snd_seq_device,snd_timer,
>> Live 0x0000000000000000
>> apple_gmux 13690 0 - Live 0x0000000000000000
>> shpchp 37201 0 - Live 0x0000000000000000
>> soundcore 12680 1 snd, Live 0x0000000000000000
>> lpc_ich 21163 0 - Live 0x0000000000000000
>> lp 17799 0 - Live 0x0000000000000000
>> mei_me 18578 0 - Live 0x0000000000000000
>> mei 82671 1 mei_me, Live 0x0000000000000000
>> apple_bl 13993 1 apple_gmux, Live 0x0000000000000000
>> parport 42481 3 parport_pc,ppdev,lp, Live 0x0000000000000000
>> bcma 52421 1 b43, Live 0x0000000000000000
>> mac_hid 13253 0 - Live 0x0000000000000000
>> video 19859 2 i915,apple_gmux, Live 0x0000000000000000
>> hid_generic 12548 0 - Live 0x0000000000000000
>> usbhid 53067 0 - Live 0x0000000000000000
>> hid 106254 6
>> hid_magicmouse,hidp,hid_roccat_koneplus,hid_appleir,hid_generic,usbhid, Live
>> 0x0000000000000000
>> tg3 174880 0 - Live 0x0000000000000000
>> ptp 18980 1 tg3, Live 0x0000000000000000
>> firewire_ohci 45158 0 - Live 0x0000000000000000
>> pps_core 19381 1 ptp, Live 0x0000000000000000
>> firewire_core 69362 1 firewire_ohci, Live 0x0000000000000000
>> sdhci_pci 19241 0 - Live 0x0000000000000000
>> crc_itu_t 12707 1 firewire_core, Live 0x0000000000000000
>> sdhci 43409 1 sdhci_pci, Live 0x0000000000000000
>>
>> [7.4.] A: /proc/ioports
>>
>> 0000-0cf7 : PCI Bus 0000:00
>> 0000-001f : dma1
>> 0020-0021 : pic1
>> 0040-0043 : timer0
>> 0050-0053 : timer1
>> 0060-0060 : keyboard
>> 0062-0062 : EC data
>> 0064-0064 : keyboard
>> 0066-0066 : EC cmd
>> 0070-0077 : rtc0
>> 0080-008f : dma page reg
>> 00a0-00a1 : pic2
>> 00c0-00df : dma2
>> 00f0-00ff : fpu
>> 0300-031f : applesmc
>> 0400-0403 : ACPI PM1a_EVT_BLK
>> 0404-0405 : ACPI PM1a_CNT_BLK
>> 0408-040b : ACPI PM_TMR
>> 0410-0415 : ACPI CPU throttle
>> 0420-042f : ACPI GPE0_BLK
>> 0430-0433 : iTCO_wdt
>> 0450-0450 : ACPI PM2_CNT_BLK
>> 0460-047f : iTCO_wdt
>> 0500-057f : pnp 00:04
>> 0cf8-0cff : PCI conf1
>> 0d00-ffff : PCI Bus 0000:00
>> 1000-100f : pnp 00:04
>> 2000-203f : 0000:00:02.0
>> 2060-206f : 0000:00:1f.2
>> 2060-206f : ata_piix
>> 20c0-20df : 0000:00:1d.0
>> 20c0-20df : uhci_hcd
>> 2120-213f : 0000:00:1a.0
>> 2120-213f : uhci_hcd
>> 2140-2147 : 0000:00:1f.2
>> 2140-2147 : ata_piix
>> 2148-214f : 0000:00:1f.2
>> 2148-214f : ata_piix
>> 2158-215b : 0000:00:1f.2
>> 2158-215b : ata_piix
>> 215c-215f : 0000:00:1f.2
>> 215c-215f : ata_piix
>> 3000-3fff : PCI Bus 0000:06
>> efa0-efbf : 0000:00:1f.3
>> ffe0-ffef : 0000:00:1f.2
>> ffe0-ffef : ata_piix
>>
>> [7.4.] B: /proc/iomem
>>
>> 00000000-00000fff : reserved
>> 00001000-0008efff : System RAM
>> 0008f000-0008ffff : reserved
>> 00090000-0009fbff : System RAM
>> 0009fc00-000fffff : reserved
>> 000a0000-000bffff : PCI Bus 0000:00
>> 000c0000-000cedff : Video ROM
>> 000f0000-000fffff : System ROM
>> 00100000-1fffffff : System RAM
>> 01000000-0174d25d : Kernel code
>> 0174d25e-01d1a3bf : Kernel data
>> 01e74000-01fdafff : Kernel bss
>> 20000000-201fffff : reserved
>> 20000000-201fffff : pnp 00:09
>> 20200000-3fffffff : System RAM
>> 40000000-401fffff : reserved
>> 40000000-401fffff : pnp 00:09
>> 40200000-8ad33fff : System RAM
>> 8ad34000-8ad5efff : ACPI Non-volatile Storage
>> 8ad5f000-8afa1fff : ACPI Tables
>> 8afa2000-8affefff : reserved
>> 8afff000-8affffff : ACPI Tables
>> 8b000000-8f9fffff : reserved
>> 8ba00000-8f9fffff : Graphics Stolen Memory
>> 8fa00000-feafffff : PCI Bus 0000:00
>> 90000000-9fffffff : 0000:00:02.0
>> 90000000-9012bfff : BOOTFB
>> a0000000-a03fffff : 0000:00:02.0
>> a0400000-a04fffff : PCI Bus 0000:02
>> a0400000-a040ffff : 0000:02:00.0
>> a0400000-a040ffff : tg3
>> a0410000-a041ffff : 0000:02:00.0
>> a0410000-a041ffff : tg3
>> a0420000-a042ffff : 0000:02:00.1
>> a0420000-a042ffff : mmc0
>> a0500000-a05fffff : PCI Bus 0000:04
>> a0500000-a05fffff : PCI Bus 0000:05
>> a0500000-a0503fff : 0000:05:00.0
>> a0504000-a05047ff : 0000:05:00.0
>> a0504000-a05047ff : firewire_ohci
>> a0600000-a06fffff : PCI Bus 0000:03
>> a0600000-a0603fff : 0000:03:00.0
>> a0600000-a0603fff : bcma-pci-bridge
>> a0700000-a07fffff : PCI Bus 0000:02
>> a0800000-a08fffff : PCI Bus 0000:01
>> a0900000-a0903fff : 0000:00:1b.0
>> a0900000-a0903fff : ICH HD audio
>> a0906800-a0906bff : 0000:00:1d.7
>> a0906800-a0906bff : ehci_hcd
>> a0906c00-a0906fff : 0000:00:1a.7
>> a0906c00-a0906fff : ehci_hcd
>> a0907000-a09070ff : 0000:00:1f.3
>> a0907100-a090710f : 0000:00:16.0
>> a0907100-a090710f : mei_me
>> a0a00000-a4efffff : PCI Bus 0000:06
>> a4f00000-a8efffff : PCI Bus 0000:06
>> e0000000-efffffff : reserved
>> e0000000-efffffff : pnp 00:08
>> e0000000-e9cfffff : PCI MMCONFIG 0000 [bus 00-9c]
>> fec00000-fec00fff : reserved
>> fec00000-fec003ff : IOAPIC 0
>> fed00000-fed03fff : reserved
>> fed00000-fed003ff : HPET 0
>> fed00000-fed003ff : pnp 00:02
>> fed10000-fed13fff : reserved
>> fed18000-fed19fff : reserved
>> fed18000-fed18fff : pnp 00:08
>> fed19000-fed19fff : pnp 00:08
>> fed1c000-fed1ffff : reserved
>> fed1c000-fed1ffff : pnp 00:08
>> fed1f410-fed1f414 : iTCO_wdt
>> fed20000-fed3ffff : pnp 00:08
>> fed40000-fed44fff : PCI Bus 0000:00
>> fed45000-fed8ffff : pnp 00:08
>> fed90000-fed93fff : pnp 00:08
>> fee00000-fee00fff : Local APIC
>> fee00000-fee00fff : reserved
>> ff800000-ffffffff : reserved
>> 100000000-26fdfffff : System RAM
>> 26fe00000-26fffffff : RAM buffer
>>
>> [7.5.] lspci -vvv
>>
>> 00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family
>> DRAM Controller (rev 09)
>> Subsystem: Apple Inc. Device 00e6
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort+ >SERR- <PERR- INTx-
>> Latency: 0
>> Capabilities: [e0] Vendor Specific Information: Len=0c <?>
>>
>> 00:01.0 PCI bridge: Intel Corporation Xeon E3-1200/2nd Generation Core
>> Processor Family PCI Express Root Port (rev 09) (prog-if 00 [Normal decode])
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
>> I/O behind bridge: 0000f000-00000fff
>> Memory behind bridge: a0800000-a08fffff
>> Prefetchable memory behind bridge: 00000000fff00000-00000000000fffff
>> Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- <SERR- <PERR-
>> BridgeCtl: Parity- SERR- NoISA- VGA- MAbort- >Reset- FastB2B-
>> PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
>> Capabilities: [88] Subsystem: Apple Inc. Device 00e6
>> Capabilities: [80] Power Management version 3
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
>> Address: fee0f00c Data: 4191
>> Capabilities: [a0] Express (v2) Root Port (Slot+), MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 128 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr- TransPend-
>> LnkCap: Port #2, Speed 5GT/s, Width x8, ASPM L0s L1, Latency L0
>> <1us, L1 <4us
>> ClockPM- Surprise- LLActRep- BwNot+
>> LnkCtl: ASPM Disabled; RCB 64 bytes Disabled+ Retrain- CommClk-
>> ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x0, TrErr- Train- SlotClk+ DLActive-
>> BWMgmt- ABWMgmt-
>> SltCap: AttnBtn- PwrCtrl- MRL- AttnInd- PwrInd- HotPlug- Surprise-
>> Slot #1, PowerLimit 75.000W; Interlock- NoCompl+
>> SltCtl: Enable: AttnBtn- PwrFlt- MRL- PresDet- CmdCplt- HPIrq-
>> LinkChg-
>> Control: AttnInd Unknown, PwrInd Unknown, Power- Interlock-
>> SltSta: Status: AttnBtn- PowerFlt- MRL- CmdCplt- PresDet-
>> Interlock-
>> Changed: MRL- PresDet- LinkState-
>> RootCtl: ErrCorrectable- ErrNon-Fatal- ErrFatal- PMEIntEna+
>> CRSVisible-
>> RootCap: CRSVisible-
>> RootSta: PME ReqID 0000, PMEStatus- PMEPending-
>> DevCap2: Completion Timeout: Not Supported, TimeoutDis- ARIFwd-
>> DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis- ARIFwd-
>> LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -3.5dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -6dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [100 v1] Virtual Channel
>> Caps: LPEVC=0 RefClk=100ns PATEntryBits=1
>> Arb: Fixed- WRR32- WRR64- WRR128-
>> Ctrl: ArbSelect=Fixed
>> Status: InProgress-
>> VC0: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed+ WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=0 ArbSelect=Fixed TC/VC=ff
>> Status: NegoPending- InProgress-
>> Capabilities: [140 v1] Root Complex Link
>> Desc: PortNumber=02 ComponentID=01 EltType=Config
>> Link0: Desc: TargetPort=00 TargetComponent=01 AssocRCRB-
>> LinkType=MemMapped LinkValid+
>> Addr: 00000000fed19000
>> Kernel driver in use: pcieport
>>
>> 00:01.1 PCI bridge: Intel Corporation Xeon E3-1200/2nd Generation Core
>> Processor Family PCI Express Root Port (rev 09) (prog-if 00 [Normal decode])
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Bus: primary=00, secondary=06, subordinate=9c, sec-latency=0
>> I/O behind bridge: 00003000-00003fff
>> Memory behind bridge: a0a00000-a4efffff
>> Prefetchable memory behind bridge: 00000000a4f00000-00000000a8efffff
>> Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- <SERR- <PERR-
>> BridgeCtl: Parity- SERR- NoISA- VGA- MAbort- >Reset- FastB2B-
>> PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
>> Capabilities: [88] Subsystem: Apple Inc. Device 00e6
>> Capabilities: [80] Power Management version 3
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
>> Address: fee0f00c Data: 41a1
>> Capabilities: [a0] Express (v2) Root Port (Slot+), MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 128 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr- TransPend-
>> LnkCap: Port #3, Speed 5GT/s, Width x8, ASPM L0s L1, Latency L0
>> <256ns, L1 <4us
>> ClockPM- Surprise- LLActRep- BwNot+
>> LnkCtl: ASPM Disabled; RCB 64 bytes Disabled+ Retrain- CommClk+
>> ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 5GT/s, Width x4, TrErr- Train- SlotClk+ DLActive-
>> BWMgmt+ ABWMgmt-
>> SltCap: AttnBtn- PwrCtrl- MRL- AttnInd- PwrInd- HotPlug- Surprise-
>> Slot #2, PowerLimit 75.000W; Interlock- NoCompl+
>> SltCtl: Enable: AttnBtn- PwrFlt- MRL- PresDet- CmdCplt- HPIrq-
>> LinkChg-
>> Control: AttnInd Unknown, PwrInd Unknown, Power- Interlock-
>> SltSta: Status: AttnBtn- PowerFlt- MRL- CmdCplt- PresDet+
>> Interlock-
>> Changed: MRL- PresDet+ LinkState-
>> RootCtl: ErrCorrectable- ErrNon-Fatal- ErrFatal- PMEIntEna+
>> CRSVisible-
>> RootCap: CRSVisible-
>> RootSta: PME ReqID 0000, PMEStatus- PMEPending-
>> DevCap2: Completion Timeout: Not Supported, TimeoutDis- ARIFwd-
>> DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis- ARIFwd-
>> LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -3.5dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [100 v1] Virtual Channel
>> Caps: LPEVC=0 RefClk=100ns PATEntryBits=1
>> Arb: Fixed- WRR32- WRR64- WRR128-
>> Ctrl: ArbSelect=Fixed
>> Status: InProgress-
>> VC0: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed+ WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=0 ArbSelect=Fixed TC/VC=ff
>> Status: NegoPending- InProgress-
>> Capabilities: [140 v1] Root Complex Link
>> Desc: PortNumber=03 ComponentID=01 EltType=Config
>> Link0: Desc: TargetPort=00 TargetComponent=01 AssocRCRB-
>> LinkType=MemMapped LinkValid+
>> Addr: 00000000fed19000
>> Kernel driver in use: pcieport
>>
>> 00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core
>> Processor Family Integrated Graphics Controller (rev 09) (prog-if 00 [VGA
>> controller])
>> Subsystem: Apple Inc. Device 00e6
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin A routed to IRQ 46
>> Region 0: Memory at a0000000 (64-bit, non-prefetchable) [size=4M]
>> Region 2: Memory at 90000000 (64-bit, prefetchable) [size=256M]
>> Region 4: I/O ports at 2000 [size=64]
>> Expansion ROM at <unassigned> [disabled]
>> Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
>> Address: fee0f00c Data: 4152
>> Capabilities: [d0] Power Management version 2
>> Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA
>> PME(D0-,D1-,D2-,D3hot-,D3cold-)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [a4] PCI Advanced Features
>> AFCap: TP+ FLR+
>> AFCtrl: FLR-
>> AFStatus: TP-
>> Kernel driver in use: i915
>>
>> 00:16.0 Communication controller: Intel Corporation 6 Series/C200 Series
>> Chipset Family MEI Controller #1 (rev 04)
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin A routed to IRQ 45
>> Region 0: Memory at a0907100 (64-bit, non-prefetchable) [size=16]
>> Capabilities: [50] Power Management version 3
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [8c] MSI: Enable+ Count=1/1 Maskable- 64bit+
>> Address: 00000000fee0f00c Data: 4142
>> Kernel driver in use: mei_me
>>
>> 00:1a.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family
>> USB Universal Host Controller #5 (rev 05) (prog-if 00 [UHCI])
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O+ Mem- BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin B routed to IRQ 21
>> Region 4: I/O ports at 2120 [size=32]
>> Capabilities: [50] PCI Advanced Features
>> AFCap: TP+ FLR+
>> AFCtrl: FLR-
>> AFStatus: TP-
>> Kernel driver in use: uhci_hcd
>>
>> 00:1a.7 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family
>> USB Enhanced Host Controller #2 (rev 05) (prog-if 20 [EHCI])
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin A routed to IRQ 23
>> Region 0: Memory at a0906c00 (32-bit, non-prefetchable) [size=1K]
>> Capabilities: [50] Power Management version 2
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=375mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [58] Debug port: BAR=1 offset=00a0
>> Capabilities: [98] PCI Advanced Features
>> AFCap: TP+ FLR+
>> AFCtrl: FLR-
>> AFStatus: TP+
>> Kernel driver in use: ehci-pci
>>
>> 00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family
>> High Definition Audio Controller (rev 05)
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Interrupt: pin A routed to IRQ 47
>> Region 0: Memory at a0900000 (64-bit, non-prefetchable) [size=16K]
>> Capabilities: [50] Power Management version 2
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=55mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [60] MSI: Enable+ Count=1/1 Maskable- 64bit+
>> Address: 00000000fee0f00c Data: 4162
>> Capabilities: [70] Express (v1) Root Complex Integrated Endpoint, MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- RBE- FLReset+
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 128 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend-
>> LnkCap: Port #0, Speed unknown, Width x0, ASPM unknown, Latency L0
>> <64ns, L1 <1us
>> ClockPM- Surprise- LLActRep- BwNot-
>> LnkCtl: ASPM Disabled; Disabled- Retrain- CommClk-
>> ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed unknown, Width x0, TrErr- Train- SlotClk- DLActive-
>> BWMgmt- ABWMgmt-
>> Capabilities: [100 v1] Virtual Channel
>> Caps: LPEVC=0 RefClk=100ns PATEntryBits=1
>> Arb: Fixed- WRR32- WRR64- WRR128-
>> Ctrl: ArbSelect=Fixed
>> Status: InProgress-
>> VC0: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=0 ArbSelect=Fixed TC/VC=01
>> Status: NegoPending- InProgress-
>> VC1: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=1 ArbSelect=Fixed TC/VC=22
>> Status: NegoPending- InProgress-
>> Capabilities: [130 v1] Root Complex Link
>> Desc: PortNumber=0f ComponentID=00 EltType=Config
>> Link0: Desc: TargetPort=00 TargetComponent=00 AssocRCRB-
>> LinkType=MemMapped LinkValid+
>> Addr: 00000000fed1c000
>> Kernel driver in use: snd_hda_intel
>>
>> 00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
>> Express Root Port 1 (rev b5) (prog-if 00 [Normal decode])
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Bus: primary=00, secondary=02, subordinate=02, sec-latency=0
>> I/O behind bridge: 0000f000-00000fff
>> Memory behind bridge: a0700000-a07fffff
>> Prefetchable memory behind bridge: 00000000a0400000-00000000a04fffff
>> Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort+ <SERR- <PERR-
>> BridgeCtl: Parity- SERR- NoISA- VGA- MAbort- >Reset- FastB2B-
>> PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
>> Capabilities: [40] Express (v2) Root Port (Slot+), MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal+ Fatal+ Unsupported+
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 128 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend-
>> LnkCap: Port #1, Speed 5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <512ns, L1 <16us
>> ClockPM- Surprise- LLActRep+ BwNot-
>> LnkCtl: ASPM L1 Enabled; RCB 64 bytes Disabled- Retrain- CommClk+
>> ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive+
>> BWMgmt+ ABWMgmt-
>> SltCap: AttnBtn- PwrCtrl- MRL- AttnInd- PwrInd- HotPlug- Surprise-
>> Slot #0, PowerLimit 10.000W; Interlock- NoCompl+
>> SltCtl: Enable: AttnBtn- PwrFlt- MRL- PresDet- CmdCplt- HPIrq-
>> LinkChg-
>> Control: AttnInd Unknown, PwrInd Unknown, Power- Interlock-
>> SltSta: Status: AttnBtn- PowerFlt- MRL- CmdCplt- PresDet+
>> Interlock-
>> Changed: MRL- PresDet- LinkState+
>> RootCtl: ErrCorrectable- ErrNon-Fatal- ErrFatal- PMEIntEna+
>> CRSVisible-
>> RootCap: CRSVisible-
>> RootSta: PME ReqID 0000, PMEStatus- PMEPending-
>> DevCap2: Completion Timeout: Range BC, TimeoutDis+ ARIFwd-
>> DevCtl2: Completion Timeout: 260ms to 900ms, TimeoutDis- ARIFwd-
>> LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -6dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [80] MSI: Enable+ Count=1/1 Maskable- 64bit-
>> Address: fee0f00c Data: 41b1
>> Capabilities: [90] Subsystem: Intel Corporation Apple MacBookPro8,2 [Core
>> i7, 15", 2011]
>> Capabilities: [a0] Power Management version 2
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Kernel driver in use: pcieport
>>
>> 00:1c.1 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
>> Express Root Port 2 (rev b5) (prog-if 00 [Normal decode])
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Bus: primary=00, secondary=03, subordinate=03, sec-latency=0
>> I/O behind bridge: 0000f000-00000fff
>> Memory behind bridge: a0600000-a06fffff
>> Prefetchable memory behind bridge: 00000000fff00000-00000000000fffff
>> Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort+ <SERR- <PERR-
>> BridgeCtl: Parity- SERR- NoISA- VGA- MAbort- >Reset- FastB2B-
>> PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
>> Capabilities: [40] Express (v2) Root Port (Slot+), MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal+ Fatal+ Unsupported+
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 128 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend-
>> LnkCap: Port #2, Speed 5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <512ns, L1 <16us
>> ClockPM- Surprise- LLActRep+ BwNot-
>> LnkCtl: ASPM L0s L1 Enabled; RCB 64 bytes Disabled- Retrain-
>> CommClk+
>> ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive+
>> BWMgmt+ ABWMgmt-
>> SltCap: AttnBtn- PwrCtrl- MRL- AttnInd- PwrInd- HotPlug- Surprise-
>> Slot #0, PowerLimit 10.000W; Interlock- NoCompl+
>> SltCtl: Enable: AttnBtn- PwrFlt- MRL- PresDet- CmdCplt- HPIrq-
>> LinkChg-
>> Control: AttnInd Unknown, PwrInd Unknown, Power- Interlock-
>> SltSta: Status: AttnBtn- PowerFlt- MRL- CmdCplt- PresDet+
>> Interlock-
>> Changed: MRL- PresDet- LinkState+
>> RootCtl: ErrCorrectable- ErrNon-Fatal- ErrFatal- PMEIntEna+
>> CRSVisible-
>> RootCap: CRSVisible-
>> RootSta: PME ReqID 0000, PMEStatus- PMEPending-
>> DevCap2: Completion Timeout: Range BC, TimeoutDis+ ARIFwd-
>> DevCtl2: Completion Timeout: 260ms to 900ms, TimeoutDis- ARIFwd-
>> LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -6dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [80] MSI: Enable+ Count=1/1 Maskable- 64bit-
>> Address: fee0f00c Data: 41d1
>> Capabilities: [90] Subsystem: Intel Corporation Apple MacBookPro8,2 [Core
>> i7, 15", 2011]
>> Capabilities: [a0] Power Management version 2
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Kernel driver in use: pcieport
>>
>> 00:1c.2 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI
>> Express Root Port 3 (rev b5) (prog-if 00 [Normal decode])
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Bus: primary=00, secondary=04, subordinate=05, sec-latency=0
>> I/O behind bridge: 0000f000-00000fff
>> Memory behind bridge: a0500000-a05fffff
>> Prefetchable memory behind bridge: 00000000fff00000-00000000000fffff
>> Secondary status: 66MHz- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort+ <SERR- <PERR-
>> BridgeCtl: Parity- SERR- NoISA- VGA- MAbort- >Reset- FastB2B-
>> PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
>> Capabilities: [40] Express (v2) Root Port (Slot+), MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal+ Fatal+ Unsupported+
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 128 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend-
>> LnkCap: Port #3, Speed 5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <512ns, L1 <16us
>> ClockPM- Surprise- LLActRep+ BwNot-
>> LnkCtl: ASPM Disabled; RCB 64 bytes Disabled- Retrain- CommClk+
>> ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive+
>> BWMgmt+ ABWMgmt-
>> SltCap: AttnBtn- PwrCtrl- MRL- AttnInd- PwrInd- HotPlug- Surprise-
>> Slot #0, PowerLimit 10.000W; Interlock- NoCompl+
>> SltCtl: Enable: AttnBtn- PwrFlt- MRL- PresDet- CmdCplt- HPIrq-
>> LinkChg-
>> Control: AttnInd Unknown, PwrInd Unknown, Power- Interlock-
>> SltSta: Status: AttnBtn- PowerFlt- MRL- CmdCplt- PresDet+
>> Interlock-
>> Changed: MRL- PresDet- LinkState+
>> RootCtl: ErrCorrectable- ErrNon-Fatal- ErrFatal- PMEIntEna+
>> CRSVisible-
>> RootCap: CRSVisible-
>> RootSta: PME ReqID 0000, PMEStatus- PMEPending-
>> DevCap2: Completion Timeout: Range BC, TimeoutDis+ ARIFwd-
>> DevCtl2: Completion Timeout: 260ms to 900ms, TimeoutDis- ARIFwd-
>> LnkCtl2: Target Link Speed: 5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -6dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [80] MSI: Enable+ Count=1/1 Maskable- 64bit-
>> Address: fee0f00c Data: 4122
>> Capabilities: [90] Subsystem: Intel Corporation Apple MacBookPro8,2 [Core
>> i7, 15", 2011]
>> Capabilities: [a0] Power Management version 2
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Kernel driver in use: pcieport
>>
>> 00:1d.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family
>> USB Universal Host Controller #1 (rev 05) (prog-if 00 [UHCI])
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O+ Mem- BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin B routed to IRQ 19
>> Region 4: I/O ports at 20c0 [size=32]
>> Capabilities: [50] PCI Advanced Features
>> AFCap: TP+ FLR+
>> AFCtrl: FLR-
>> AFStatus: TP-
>> Kernel driver in use: uhci_hcd
>>
>> 00:1d.7 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family
>> USB Enhanced Host Controller #1 (rev 05) (prog-if 20 [EHCI])
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin A routed to IRQ 22
>> Region 0: Memory at a0906800 (32-bit, non-prefetchable) [size=1K]
>> Capabilities: [50] Power Management version 2
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=375mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [58] Debug port: BAR=1 offset=00a0
>> Capabilities: [98] PCI Advanced Features
>> AFCap: TP+ FLR+
>> AFCtrl: FLR-
>> AFStatus: TP-
>> Kernel driver in use: ehci-pci
>>
>> 00:1f.0 ISA bridge: Intel Corporation HM65 Express Chipset Family LPC
>> Controller (rev 05)
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Capabilities: [e0] Vendor Specific Information: Len=0c <?>
>> Kernel driver in use: lpc_ich
>>
>> 00:1f.2 IDE interface: Intel Corporation 6 Series/C200 Series Chipset Family 4
>> port SATA IDE Controller (rev 05) (prog-if 8f [Master SecP SecO PriP PriO])
>> Subsystem: Intel Corporation Device 7270
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0
>> Interrupt: pin B routed to IRQ 19
>> Region 0: I/O ports at 2148 [size=8]
>> Region 1: I/O ports at 215c [size=4]
>> Region 2: I/O ports at 2140 [size=8]
>> Region 3: I/O ports at 2158 [size=4]
>> Region 4: I/O ports at 2060 [size=16]
>> Region 5: I/O ports at ffe0 [size=16]
>> Capabilities: [70] Power Management version 3
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0-,D1-,D2-,D3hot-,D3cold-)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
>> Capabilities: [b0] PCI Advanced Features
>> AFCap: TP+ FLR+
>> AFCtrl: FLR-
>> AFStatus: TP-
>> Kernel driver in use: ata_piix
>>
>> 00:1f.3 SMBus: Intel Corporation 6 Series/C200 Series Chipset Family SMBus
>> Controller (rev 05)
>> Subsystem: Intel Corporation Apple MacBookPro8,2 [Core i7, 15", 2011]
>> Control: I/O+ Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Interrupt: pin C routed to IRQ 11
>> Region 0: Memory at a0907000 (64-bit, non-prefetchable) [size=256]
>> Region 4: I/O ports at efa0 [size=32]
>>
>> 02:00.0 Ethernet controller: Broadcom Corporation NetXtreme BCM57765 Gigabit
>> Ethernet PCIe (rev 10)
>> Subsystem: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx+
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Interrupt: pin A routed to IRQ 16
>> Region 0: Memory at a0400000 (64-bit, prefetchable) [size=64K]
>> Region 2: Memory at a0410000 (64-bit, prefetchable) [size=64K]
>> Capabilities: [48] Power Management version 3
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=1 PME-
>> Capabilities: [58] MSI: Enable- Count=1/8 Maskable- 64bit+
>> Address: 0000000000000000 Data: 0000
>> Capabilities: [a0] MSI-X: Enable+ Count=6 Masked-
>> Vector table: BAR=2 offset=00000000
>> PBA: BAR=2 offset=00000120
>> Capabilities: [ac] Express (v2) Endpoint, MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <4us, L1
>> <64us
>> ExtTag- AttnBtn- AttnInd- PwrInd- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr+ NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 4096 bytes
>> DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend-
>> LnkCap: Port #0, Speed 2.5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <2us, L1 <64us
>> ClockPM+ Surprise- LLActRep- BwNot-
>> LnkCtl: ASPM L1 Enabled; RCB 64 bytes Disabled- Retrain- CommClk+
>> ExtSynch- ClockPM+ AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive-
>> BWMgmt- ABWMgmt-
>> DevCap2: Completion Timeout: Range ABCD, TimeoutDis+
>> DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis-
>> LnkCtl2: Target Link Speed: 2.5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -6dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -6dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [100 v1] Advanced Error Reporting
>> UESta: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UEMsk: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UESvrt: DLP+ SDES+ TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+
>> MalfTLP+ ECRC- UnsupReq- ACSViol-
>> CESta: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> CEMsk: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> AERCap: First Error Pointer: 00, GenCap+ CGenEn- ChkCap+ ChkEn-
>> Capabilities: [13c v1] Device Serial Number 00-00-3c-07-54-53-3a-a7
>> Capabilities: [150 v1] Power Budgeting <?>
>> Capabilities: [160 v1] Virtual Channel
>> Caps: LPEVC=0 RefClk=100ns PATEntryBits=1
>> Arb: Fixed- WRR32- WRR64- WRR128-
>> Ctrl: ArbSelect=Fixed
>> Status: InProgress-
>> VC0: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=0 ArbSelect=Fixed TC/VC=ff
>> Status: NegoPending- InProgress-
>> Kernel driver in use: tg3
>>
>> 02:00.1 SD Host controller: Broadcom Corporation BCM57765/57785 SDXC/MMC Card
>> Reader (rev 10) (prog-if 01)
>> Subsystem: Broadcom Corporation Device 0000
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Interrupt: pin B routed to IRQ 17
>> Region 0: Memory at a0420000 (64-bit, prefetchable) [size=64K]
>> Capabilities: [48] Power Management version 3
>> Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
>> PME(D0+,D1-,D2-,D3hot+,D3cold+)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=1 PME-
>> Capabilities: [58] MSI: Enable- Count=1/1 Maskable- 64bit+
>> Address: 0000000000000000 Data: 0000
>> Capabilities: [ac] Express (v2) Endpoint, MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <4us, L1
>> <64us
>> ExtTag- AttnBtn- AttnInd- PwrInd- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd+ ExtTag- PhantFunc- AuxPwr+ NoSnoop+
>> MaxPayload 128 bytes, MaxReadReq 4096 bytes
>> DevSta: CorrErr+ UncorrErr- FatalErr- UnsuppReq+ AuxPwr+ TransPend-
>> LnkCap: Port #0, Speed 2.5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <2us, L1 <64us
>> ClockPM+ Surprise- LLActRep- BwNot-
>> LnkCtl: ASPM L1 Enabled; RCB 64 bytes Disabled- Retrain- CommClk+
>> ExtSynch- ClockPM+ AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive-
>> BWMgmt- ABWMgmt-
>> DevCap2: Completion Timeout: Range ABCD, TimeoutDis+
>> DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis-
>> LnkCtl2: Target Link Speed: 2.5GT/s, EnterCompliance- SpeedDis-,
>> Selectable De-emphasis: -6dB
>> Transmit Margin: Normal Operating Range, EnterModifiedCompliance-
>> ComplianceSOS-
>> Compliance De-emphasis: -6dB
>> LnkSta2: Current De-emphasis Level: -6dB, EqualizationComplete-,
>> EqualizationPhase1-
>> EqualizationPhase2-, EqualizationPhase3-,
>> LinkEqualizationRequest-
>> Capabilities: [100 v1] Advanced Error Reporting
>> UESta: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UEMsk: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UESvrt: DLP+ SDES+ TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+
>> MalfTLP+ ECRC- UnsupReq- ACSViol-
>> CESta: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> CEMsk: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> AERCap: First Error Pointer: 00, GenCap+ CGenEn- ChkCap+ ChkEn-
>> Capabilities: [150 v1] Power Budgeting <?>
>> Capabilities: [160 v1] Virtual Channel
>> Caps: LPEVC=0 RefClk=100ns PATEntryBits=1
>> Arb: Fixed- WRR32- WRR64- WRR128-
>> Ctrl: ArbSelect=Fixed
>> Status: InProgress-
>> VC0: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=0 ArbSelect=Fixed TC/VC=ff
>> Status: NegoPending- InProgress-
>> Kernel driver in use: sdhci-pci
>>
>> 03:00.0 Network controller: Broadcom Corporation BCM4331 802.11a/b/g/n (rev
>> 02)
>> Subsystem: Broadcom Corporation BCM4331 802.11a/b/g/n
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Interrupt: pin A routed to IRQ 17
>> Region 0: Memory at a0600000 (64-bit, non-prefetchable) [size=16K]
>> Capabilities: [40] Power Management version 3
>> Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA
>> PME(D0-,D1-,D2-,D3hot-,D3cold-)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=2 PME-
>> Capabilities: [58] Vendor Specific Information: Len=78 <?>
>> Capabilities: [48] MSI: Enable- Count=1/1 Maskable- 64bit+
>> Address: 0000000000000000 Data: 0000
>> Capabilities: [d0] Express (v1) Endpoint, MSI 00
>> DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <4us, L1
>> unlimited
>> ExtTag+ AttnBtn- AttnInd- PwrInd- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop-
>> MaxPayload 128 bytes, MaxReadReq 512 bytes
>> DevSta: CorrErr+ UncorrErr- FatalErr- UnsuppReq+ AuxPwr+ TransPend-
>> LnkCap: Port #0, Speed 2.5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <2us, L1 <32us
>> ClockPM+ Surprise- LLActRep+ BwNot-
>> LnkCtl: ASPM L0s L1 Enabled; RCB 64 bytes Disabled- Retrain-
>> CommClk+
>> ExtSynch- ClockPM+ AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive+
>> BWMgmt- ABWMgmt-
>> Capabilities: [100 v1] Advanced Error Reporting
>> UESta: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UEMsk: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UESvrt: DLP+ SDES- TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+
>> MalfTLP+ ECRC- UnsupReq- ACSViol-
>> CESta: RxErr- BadTLP- BadDLLP+ Rollover- Timeout- NonFatalErr+
>> CEMsk: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> AERCap: First Error Pointer: 14, GenCap+ CGenEn- ChkCap+ ChkEn-
>> Capabilities: [13c v1] Virtual Channel
>> Caps: LPEVC=0 RefClk=100ns PATEntryBits=1
>> Arb: Fixed- WRR32- WRR64- WRR128-
>> Ctrl: ArbSelect=Fixed
>> Status: InProgress-
>> VC0: Caps: PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
>> Arb: Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
>> Ctrl: Enable+ ID=0 ArbSelect=Fixed TC/VC=ff
>> Status: NegoPending- InProgress-
>> Capabilities: [160 v1] Device Serial Number 00-00-00-ff-ff-00-00-00
>> Capabilities: [16c v1] Power Budgeting <?>
>> Kernel driver in use: bcma-pci-bridge
>>
>> 04:00.0 PCI bridge: Texas Instruments XIO2213A/B/XIO2221 PCI Express to PCI
>> Bridge [Cheetah Express] (rev 01) (prog-if 00 [Normal decode])
>> Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV+ VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 0, Cache Line Size: 256 bytes
>> Bus: primary=04, secondary=05, subordinate=05, sec-latency=0
>> I/O behind bridge: 0000f000-00000fff
>> Memory behind bridge: a0500000-a05fffff
>> Prefetchable memory behind bridge: 00000000fff00000-00000000000fffff
>> Secondary status: 66MHz+ FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort+ <SERR- <PERR-
>> BridgeCtl: Parity- SERR- NoISA- VGA- MAbort- >Reset- FastB2B-
>> PriDiscTmr- SecDiscTmr- DiscTmrStat- DiscTmrSERREn-
>> Capabilities: [50] Power Management version 3
>> Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA
>> PME(D0-,D1-,D2-,D3hot-,D3cold-)
>> Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
>> Bridge: PM- B3+
>> Capabilities: [60] MSI: Enable- Count=1/16 Maskable- 64bit+
>> Address: 0000000000000000 Data: 0000
>> Capabilities: [80] Subsystem: Device 0000:0000
>> Capabilities: [90] Express (v1) PCI/PCI-X Bridge, MSI 00
>> DevCap: MaxPayload 512 bytes, PhantFunc 0, Latency L0s <64ns, L1
>> <1us
>> ExtTag- AttnBtn- AttnInd- PwrInd- RBE+ FLReset-
>> DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
>> RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop+ BrConfRtry-
>> MaxPayload 128 bytes, MaxReadReq 512 bytes
>> DevSta: CorrErr+ UncorrErr- FatalErr- UnsuppReq+ AuxPwr- TransPend-
>> LnkCap: Port #0, Speed 2.5GT/s, Width x1, ASPM L0s L1, Latency L0
>> <512ns, L1 <16us
>> ClockPM+ Surprise- LLActRep- BwNot-
>> LnkCtl: ASPM Disabled; Disabled- Retrain- CommClk+
>> ExtSynch- ClockPM+ AutWidDis- BWInt- AutBWInt-
>> LnkSta: Speed 2.5GT/s, Width x1, TrErr- Train- SlotClk+ DLActive-
>> BWMgmt- ABWMgmt-
>> Capabilities: [100 v1] Advanced Error Reporting
>> UESta: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq+ ACSViol-
>> UEMsk: DLP- SDES- TLP- FCP- CmpltTO- CmpltAbrt- UnxCmplt- RxOF-
>> MalfTLP- ECRC- UnsupReq- ACSViol-
>> UESvrt: DLP+ SDES- TLP- FCP+ CmpltTO- CmpltAbrt- UnxCmplt- RxOF+
>> MalfTLP+ ECRC- UnsupReq- ACSViol-
>> CESta: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> CEMsk: RxErr- BadTLP- BadDLLP- Rollover- Timeout- NonFatalErr+
>> AERCap: First Error Pointer: 14, GenCap+ CGenEn- ChkCap+ ChkEn-
>>
>> 05:00.0 FireWire (IEEE 1394): Texas Instruments XIO2213A/B/XIO2221 IEEE-1394b
>> OHCI Controller [Cheetah Express] (rev 01) (prog-if 10 [OHCI])
>> Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV+ VGASnoop- ParErr-
>> Stepping- SERR- FastB2B- DisINTx-
>> Status: Cap+ 66MHz+ UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort-
>> <MAbort- >SERR- <PERR- INTx-
>> Latency: 248 (500ns min, 1000ns max), Cache Line Size: 64 bytes
>> Interrupt: pin A routed to IRQ 18
>> Region 0: Memory at a0504000 (32-bit, non-prefetchable) [size=2K]
>> Region 1: Memory at a0500000 (32-bit, non-prefetchable) [size=16K]
>> Capabilities: [44] Power Management version 3
>> Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA
>> PME(D0+,D1+,D2+,D3hot+,D3cold-)
>> Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME+
>> Kernel driver in use: firewire_ohci
>>
>> [7.6.] /proc/scsi/scsi :
>>
>> Attached devices:
>> Host: scsi0 Channel: 00 Id: 00 Lun: 00
>> Vendor: ATA Model: Hitachi HTS54505 Rev: PB4A
>> Type: Direct-Access ANSI SCSI revision: 05
>>
>> [7.7.] git bisect log
>>
>> git bisect start
>> # good: [8bb495e3f02401ee6f76d1b1d77f3ac9f079e376] Linux 3.10
>> git bisect good 8bb495e3f02401ee6f76d1b1d77f3ac9f079e376
>> # bad: [ad81f0545ef01ea651886dddac4bef6cec930092] Linux 3.11-rc1
>> git bisect bad ad81f0545ef01ea651886dddac4bef6cec930092
>> # good: [1286da8bc009cb2aee7f285e94623fc974c0c983] Merge tag 'sound-3.11' of
>> git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
>> git bisect good 1286da8bc009cb2aee7f285e94623fc974c0c983
>> # bad: [1b375dc30710180c4b88cc59caba6e3481ec5c8b] mutex: Move ww_mutex
>> definitions to ww_mutex.h
>> git bisect bad 1b375dc30710180c4b88cc59caba6e3481ec5c8b
>> # bad: [899dd388853071f5c8848545209d4e2c5d95b1d9] Merge tag
>> 'for-linus-3.11-merge-window-part-1' of
>> git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs
>> git bisect bad 899dd388853071f5c8848545209d4e2c5d95b1d9
>> # bad: [f5b63ac0f77ecab46796ba5d368ea5dd51834e6e] Merge branch 'for-linus' of
>> git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
>> git bisect bad f5b63ac0f77ecab46796ba5d368ea5dd51834e6e
>> # bad: [3366dd9fa887ebbda4872e9554f853eaeda764be] Merge branch 'for-linus' of
>> git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid
>> git bisect bad 3366dd9fa887ebbda4872e9554f853eaeda764be
>> # good: [c039e3a8ddd52139d0f81711ecd757772f868b22] powerpc: Handle both new
>> style and old style reserve maps
>> git bisect good c039e3a8ddd52139d0f81711ecd757772f868b22
>> # good: [e61aca5158a84932cf9fbbcbf8aef9cef63f5026] Merge branch 'kconfig-diet'
>> from Dave Hansen
>> git bisect good e61aca5158a84932cf9fbbcbf8aef9cef63f5026
>> # good: [b8e0fe31a7c8623741f91bc27f925220341fdf81] HID: wiimote: support
>> Nintendo Wii U Pro Controller
>> git bisect good b8e0fe31a7c8623741f91bc27f925220341fdf81
>> # bad: [08ec2dcc3527a20c619aca2fb36f800908256bac] Merge branches
>> 'for-3.11/multitouch', 'for-3.11/sony' and 'for-3.11/upstream' into for-linus
>> git bisect bad 08ec2dcc3527a20c619aca2fb36f800908256bac
>> # good: [db58316892a5e9034efe718d4c1630788db7528f] Merge branches
>> 'for-3.11/battery', 'for-3.11/elo', 'for-3.11/holtek' and
>> 'for-3.11/i2c-hid-fixed' into for-linus
>> git bisect good db58316892a5e9034efe718d4c1630788db7528f
>> # bad: [a688393bd3fb27690a77f7ae8607b4969039bac5] HID: explain out-of-range
>> check better
>> git bisect bad a688393bd3fb27690a77f7ae8607b4969039bac5
>> # bad: [b1a1442a23776756b254b69786848a94d92445ba] HID: core: fix reporting of
>> raw events
>> git bisect bad b1a1442a23776756b254b69786848a94d92445ba
>> # good: [68e353fe476e7dab4644b9e7b4979b72726397ae] HID: add support for Huion
>> 580 tablet
>> git bisect good 68e353fe476e7dab4644b9e7b4979b72726397ae
>> # first bad commit: [b1a1442a23776756b254b69786848a94d92445ba] HID: core: fix
>> reporting of raw events
>>
>> [7.8.] Information from syslog when kernel recovers
>>
>> Jan 26 00:55:46 gerrit-testing-1404 colord: Profile added:
>> icc-e78de847fc92f70fe2135cbd74d84353
>> Jan 26 00:55:48 gerrit-testing-1404 dbus[617]: [system] Activating service
>> name='org.freedesktop.UDisks2' (using servicehelper)
>> Jan 26 00:55:48 gerrit-testing-1404 udisksd[2304]: udisks daemon version 2.1.2
>> starting
>> Jan 26 00:55:48 gerrit-testing-1404 dbus[617]: [system] Successfully activated
>> service 'org.freedesktop.UDisks2'
>> Jan 26 00:55:48 gerrit-testing-1404 udisksd[2304]: Acquired the name
>> org.freedesktop.UDisks2 on the system message bus
>> Jan 26 00:55:49 gerrit-testing-1404 udisksd[2304]: Cleaning up mount point
>> /media/gerrit/a0632e71-0eb0-47f5-878c-20d0533ba044 (device 8:6 is not mounted)
>> Jan 26 00:56:04 gerrit-testing-1404 bluetoothd[647]: Endpoint unregistered:
>> sender=:1.45 path=/MediaEndpoint/HFPAG
>> Jan 26 00:56:04 gerrit-testing-1404 bluetoothd[647]: Endpoint unregistered:
>> sender=:1.45 path=/MediaEndpoint/HFPHS
>> Jan 26 00:56:04 gerrit-testing-1404 bluetoothd[647]: Endpoint unregistered:
>> sender=:1.45 path=/MediaEndpoint/A2DPSource
>> Jan 26 00:56:04 gerrit-testing-1404 bluetoothd[647]: Endpoint unregistered:
>> sender=:1.45 path=/MediaEndpoint/A2DPSink
>> Jan 26 00:56:24 gerrit-testing-1404 kernel: [ 174.632667] Bluetooth: HIDP
>> (Human Interface Emulation) ver 1.2
>> Jan 26 00:56:24 gerrit-testing-1404 kernel: [ 174.632685] Bluetooth: HIDP
>> socket layer initialized
>> Jan 26 00:56:27 gerrit-testing-1404 kernel: [ 177.740013] magicmouse
>> 0005:05AC:030E.0008: unknown main item tag 0x0
>> Jan 26 00:56:27 gerrit-testing-1404 kernel: [ 177.740083] input: as
>> /devices/pci0000:00/0000:00:1a.7/usb1/1-1/1-1.1/1-1.1.3/1-1.1.3:1.0/bluetooth/hci0/hci0:12/input17
>> Jan 26 00:56:27 gerrit-testing-1404 kernel: [ 177.740236] magicmouse
>> 0005:05AC:030E.0008: input,hidraw2: BLUETOOTH HID v1.60 Mouse [] on
>> 68:a8:6d:57:8f:80
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.211489] BUG: unable to
>> handle kernel NULL pointer dereference at 0000000000000048
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.211556] IP:
>> [<ffffffff8105cb16>] do_exit+0x2e6/0xa30
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.211592] PGD 0
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.211607] Thread overran
>> stack, or stack corrupted
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.211635] Oops: 0000 [#1] SMP
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.211659] Modules linked in:
>> hid_magicmouse hidp parport_pc ppdev rfcomm bnep b43 mac80211 i915
>> intel_powerclamp coretemp kvm_intel kvm cfg80211 snd_hda_codec_hdmi
>> snd_hda_codec_cirrus snd_hda_intel snd_hda_codec snd_usb_audio snd_usbmidi_lib
>> drm_kms_helper snd_hwdep snd_pcm btusb drm bluetooth snd_page_alloc
>> snd_seq_midi snd_seq_midi_event crc32_pclmul snd_rawmidi ghash_clmulni_intel
>> snd_seq aesni_intel ssb aes_x86_64 lrw gf128mul glue_helper ablk_helper
>> snd_seq_device cryptd snd_timer snd applesmc mei_me hid_roccat_koneplus mei
>> input_polldev hid_roccat joydev hid_roccat_common hid_appleir microcode
>> apple_gmux shpchp soundcore bcma i2c_algo_bit lp apple_bl parport video
>> lpc_ich mac_hid hid_generic tg3 firewire_ohci usbhid firewire_core ptp hid
>> sdhci_pci sdhci crc_itu_t pps_core
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212207] CPU: 0 PID: 2506
>> Comm: syndaemon Not tainted 3.10.0-custom-step5 #6
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212247] Hardware name:
>> Apple Inc. Macmini5,1/Mac-8ED6AF5B48C039E1, BIOS MM51.88Z.0077.B10.1201241549
>> 01/24/2012
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212303] task:
>> ffff88021e128000 ti: ffff88021e338000 task.ti: ffff88021e338000
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212343] RIP:
>> 0010:[<ffffffff8105cb16>] [<ffffffff8105cb16>] do_exit+0x2e6/0xa30
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212389] RSP:
>> 0018:ffff88021e339ec8 EFLAGS: 00010246
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212419] RAX:
>> 0000000000000000 RBX: ffff88021e128000 RCX: 00000000000000b6
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212458] RDX:
>> 00000000000000b6 RSI: 0000000000000001 RDI: 0000000000000001
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212496] RBP:
>> ffff88021e339f38 R08: ffffffff81edc800 R09: 0000000000000001
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212534] R10:
>> 0000000000000000 R11: ffffea0008798840 R12: ffff880253789a40
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212573] R13:
>> ffff88021e128630 R14: ffff880253789aa8 R15: 00007fff52b704f8
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212612] FS:
>> 0000000000000000(0000) GS:ffff88026fa00000(0000) knlGS:0000000000000000
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212655] CS: 0010 DS: 0000
>> ES: 0000 CR0: 0000000080050033
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212686] CR2:
>> 0000000000000048 CR3: 0000000001c0e000 CR4: 00000000000407f0
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212725] Stack:
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212738] ffff88021e128634
>> 0000000101bec410 ffff88021e339f00 ffffffff8108f679
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212788] 0000000000000246
>> 00007f7cb316e848 00007f7cb3173e80 ffff88021e339f18
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212836] 0000000000000246
>> ffff88026436d500 0000000000000100 ffff88021e128000
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212884] Call Trace:
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212904]
>> [<ffffffff8108f679>] ? vtime_account_user+0x69/0x80
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212939]
>> [<ffffffff8105d2df>] do_group_exit+0x3f/0xa0
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.212971]
>> [<ffffffff8105d354>] SyS_exit_group+0x14/0x20
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.213006]
>> [<ffffffff816d7d2f>] tracesys+0xe1/0xe6
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.213034] Code: ff 48 89 df
>> e8 5c d1 0c 00 be 01 00 00 00 48 89 df e8 9f f5 06 00 44 8b 4d 9c 45 85 c9 0f
>> 85 8b 04 00 00 48 8b 43 08 48 8b 40 08 <48> 8b 78 48 e8 31 dc 05 00 48 89 df
>> e8 a9 f3 3e 00 48 89 df e8
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.213289] RIP
>> [<ffffffff8105cb16>] do_exit+0x2e6/0xa30
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.213324] RSP
>> <ffff88021e339ec8>
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.213344] CR2:
>> 0000000000000048
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.226977] ---[ end trace
>> 79422433cc8a77d4 ]---
>> Jan 26 00:56:29 gerrit-testing-1404 kernel: [ 180.226986] Fixing recursive
>> fault but reboot is needed!
>>
^ permalink raw reply
* Re: [PATCH 0/6] HID: Add a stable method for retrieving the client MAC address of a HID device
From: Frank Praznik @ 2014-02-01 16:06 UTC (permalink / raw)
To: Benjamin Tissoires, Frank Praznik
Cc: linux-input, Jiri Kosina, David Herrmann
In-Reply-To: <CAN+gG=GxXUU2rNNg7T1o50RPzXopnnqWbhQ4+-uWN3mbLUUyDw@mail.gmail.com>
On 1/31/2014 15:45, Benjamin Tissoires wrote:
> On Fri, Jan 31, 2014 at 3:04 PM, Frank Praznik <frank.praznik@oh.rr.com> wrote:
>> On 1/31/2014 14:10, Benjamin Tissoires wrote:
>>> Hi Frank,
>>>
>>> just a quick review:
>>>
>>> On Fri, Jan 31, 2014 at 12:32 PM, Frank Praznik <frank.praznik@oh.rr.com>
>>> wrote:
>>>> Currently there is no reliable way for a device module or hidraw
>>>> application to
>>>> retrieve the client MAC address of the associated wireless device. This
>>>> series
>>>> of patches adds a stable way of retrieving this information.
>>> Well, if I look at the uevent of a Bluetooth mouse I have:
>>>
>>> $ cat
>>> /sys/devices/pci0000\:00/0000\:00\:14.0/usb3/3-2/3-2\:1.0/bluetooth/hci0/hci0\:43/0005\:046D\:B00D.001F/uevent
>>> DRIVER=hid-generic
>>> HID_ID=0005:0000046D:0000B00D
>>> HID_NAME=Ultrathin Touch Mouse
>>> HID_PHYS=00:10:60:ea:df:ae
>>> HID_UNIQ=00:1f:20:96:33:47
>>> MODALIAS=hid:b0005g0001v0000046Dp0000B00D
>>>
>>> I would say that HID_UNIQ is the client MAC address set by hidp, no?
>>> So you don't need to duplicate the info by adding a new field in
>>> hid_device.
>>>
>> In a patch I recently submitted I was using the UNIQ field for retrieving a
>> Bluetooth device MAC address and was warned against it because "UNIQ is a
>> way to provide unique identifiers for devices, but it's not guaranteed to
>> stay the same". HIDP happens to store the MAC in the UNIQ data, but there
>> is no guarantee that it will always be there. With these patches you can be
>> completely sure that the data in client_addr is the client device MAC
>> address.
> ok. But still, adding a transport-specific information to hid_device
> is IMO a bad idea. We fought to make HID agnostic of the transport
> layer enough.
>
> David, could you elaborate why you think that UNIQ may change in the
> future regarding BT?
> If the BT MAC address is the same principle of an ethernet MAC
> address, UNIQ seems to fit perfectly well.
>
> Otherwise, you may be able to retrieve the MAC address by using the
> parent of the current device.
>
> Cheers,
> Benjamin
Are you referring to using the hid_device::dev.parent pointer? I know
that hidp sets it to point to the hci_conn struct from which src address
for the Bluetooth connection can be obtained, but making assumptions
about an opaque pointer like that seems dangerous. Is the parent
pointer guaranteed to point to the hci_conn struct as long as the bus
type is Bluetooth?
^ permalink raw reply
* Re: [PATCH 0/6] HID: Add a stable method for retrieving the client MAC address of a HID device
From: Benjamin Tissoires @ 2014-02-01 16:28 UTC (permalink / raw)
To: Frank Praznik; +Cc: Frank Praznik, linux-input, Jiri Kosina, David Herrmann
In-Reply-To: <52ED1B8D.80208@gmail.com>
On Sat, Feb 1, 2014 at 11:06 AM, Frank Praznik <frank.praznik@gmail.com> wrote:
> On 1/31/2014 15:45, Benjamin Tissoires wrote:
>>
>> On Fri, Jan 31, 2014 at 3:04 PM, Frank Praznik <frank.praznik@oh.rr.com>
>> wrote:
>>>
>>> On 1/31/2014 14:10, Benjamin Tissoires wrote:
>>>>
>>>> Hi Frank,
>>>>
>>>> just a quick review:
>>>>
>>>> On Fri, Jan 31, 2014 at 12:32 PM, Frank Praznik
>>>> <frank.praznik@oh.rr.com>
>>>> wrote:
>>>>>
>>>>> Currently there is no reliable way for a device module or hidraw
>>>>> application to
>>>>> retrieve the client MAC address of the associated wireless device.
>>>>> This
>>>>> series
>>>>> of patches adds a stable way of retrieving this information.
>>>>
>>>> Well, if I look at the uevent of a Bluetooth mouse I have:
>>>>
>>>> $ cat
>>>>
>>>> /sys/devices/pci0000\:00/0000\:00\:14.0/usb3/3-2/3-2\:1.0/bluetooth/hci0/hci0\:43/0005\:046D\:B00D.001F/uevent
>>>> DRIVER=hid-generic
>>>> HID_ID=0005:0000046D:0000B00D
>>>> HID_NAME=Ultrathin Touch Mouse
>>>> HID_PHYS=00:10:60:ea:df:ae
>>>> HID_UNIQ=00:1f:20:96:33:47
>>>> MODALIAS=hid:b0005g0001v0000046Dp0000B00D
>>>>
>>>> I would say that HID_UNIQ is the client MAC address set by hidp, no?
>>>> So you don't need to duplicate the info by adding a new field in
>>>> hid_device.
>>>>
>>> In a patch I recently submitted I was using the UNIQ field for retrieving
>>> a
>>> Bluetooth device MAC address and was warned against it because "UNIQ is a
>>> way to provide unique identifiers for devices, but it's not guaranteed to
>>> stay the same". HIDP happens to store the MAC in the UNIQ data, but
>>> there
>>> is no guarantee that it will always be there. With these patches you can
>>> be
>>> completely sure that the data in client_addr is the client device MAC
>>> address.
>>
>> ok. But still, adding a transport-specific information to hid_device
>> is IMO a bad idea. We fought to make HID agnostic of the transport
>> layer enough.
>>
>> David, could you elaborate why you think that UNIQ may change in the
>> future regarding BT?
>> If the BT MAC address is the same principle of an ethernet MAC
>> address, UNIQ seems to fit perfectly well.
>>
>> Otherwise, you may be able to retrieve the MAC address by using the
>> parent of the current device.
>>
>> Cheers,
>> Benjamin
>
> Are you referring to using the hid_device::dev.parent pointer? I know that
Yes
> hidp sets it to point to the hci_conn struct from which src address for the
> Bluetooth connection can be obtained, but making assumptions about an opaque
> pointer like that seems dangerous. Is the parent pointer guaranteed to
> point to the hci_conn struct as long as the bus type is Bluetooth?
And nope. If you use uhid, then the parent will not be a hci_conn.
With enough guards, you should be able to use it, but it's not ideal I agree.
I really want to have David's opinion regarding the UNIQ field. IMO,
this seems to be the most transport-agnostic way of doing it.
Cheers,
Benjamin
^ permalink raw reply
* [PATCH] HID: fix buffer allocations
From: Benjamin Tissoires @ 2014-02-02 4:23 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, linux-input, linux-kernel
When using hid_output_report(), the buffer should be allocated by hid_alloc_report_buf(),
not a custom malloc.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/hid-input.c | 2 +-
drivers/hid/i2c-hid/i2c-hid.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index d50e731..a713e62 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -1178,7 +1178,7 @@ static void hidinput_led_worker(struct work_struct *work)
/* fall back to generic raw-output-report */
len = ((report->size - 1) >> 3) + 1 + (report->id > 0);
- buf = kmalloc(len, GFP_KERNEL);
+ buf = hid_alloc_report_buf(report, GFP_KERNEL);
if (!buf)
return;
diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c
index e914f27..ce68a12 100644
--- a/drivers/hid/i2c-hid/i2c-hid.c
+++ b/drivers/hid/i2c-hid/i2c-hid.c
@@ -582,7 +582,7 @@ static void i2c_hid_request(struct hid_device *hid, struct hid_report *rep,
int ret;
int len = i2c_hid_get_report_length(rep) - 2;
- buf = kzalloc(len, GFP_KERNEL);
+ buf = hid_alloc_report_buf(rep, GFP_KERNEL);
if (!buf)
return;
--
1.8.3.1
^ permalink raw reply related
* [PATCH 01/11] HID: uHID: implement .raw_request
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
It was missing, so adding it.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/uhid.c | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
diff --git a/drivers/hid/uhid.c b/drivers/hid/uhid.c
index f5a2b19..438c9f1 100644
--- a/drivers/hid/uhid.c
+++ b/drivers/hid/uhid.c
@@ -270,6 +270,22 @@ static int uhid_hid_output_report(struct hid_device *hid, __u8 *buf,
return count;
}
+static int uhid_raw_request(struct hid_device *hid, unsigned char reportnum,
+ __u8 *buf, size_t len, unsigned char rtype,
+ int reqtype)
+{
+ switch (reqtype) {
+ case HID_REQ_GET_REPORT:
+ return uhid_hid_get_raw(hid, reportnum, buf, len, rtype);
+ case HID_REQ_SET_REPORT:
+ if (buf[0] != reportnum)
+ return -EINVAL;
+ return uhid_hid_output_raw(hid, buf, len, rtype);
+ default:
+ return -EIO;
+ }
+}
+
static struct hid_ll_driver uhid_hid_driver = {
.start = uhid_hid_start,
.stop = uhid_hid_stop,
@@ -277,6 +293,7 @@ static struct hid_ll_driver uhid_hid_driver = {
.close = uhid_hid_close,
.parse = uhid_hid_parse,
.output_report = uhid_hid_output_report,
+ .raw_request = uhid_raw_request,
};
#ifdef CONFIG_COMPAT
--
1.8.3.1
^ permalink raw reply related
* [PATCH 02/11] HID: i2c-hid: implement ll_driver transport-layer callbacks
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
Add output_report and raw_request to i2c-hid.
Hopefully, we will manage to have the same transport level between
all the transport drivers.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/i2c-hid/i2c-hid.c | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c
index ce68a12..5099f1f 100644
--- a/drivers/hid/i2c-hid/i2c-hid.c
+++ b/drivers/hid/i2c-hid/i2c-hid.c
@@ -574,6 +574,28 @@ static int i2c_hid_output_raw_report(struct hid_device *hid, __u8 *buf,
return ret;
}
+static int i2c_hid_output_report(struct hid_device *hid, __u8 *buf,
+ size_t count)
+{
+ return i2c_hid_output_raw_report(hid, buf, count, HID_OUTPUT_REPORT);
+}
+
+static int i2c_hid_raw_request(struct hid_device *hid, unsigned char reportnum,
+ __u8 *buf, size_t len, unsigned char rtype,
+ int reqtype)
+{
+ switch (reqtype) {
+ case HID_REQ_GET_REPORT:
+ return i2c_hid_get_raw_report(hid, reportnum, buf, len, rtype);
+ case HID_REQ_SET_REPORT:
+ if (buf[0] != reportnum)
+ return -EINVAL;
+ return i2c_hid_output_raw_report(hid, buf, len, rtype);
+ default:
+ return -EIO;
+ }
+}
+
static void i2c_hid_request(struct hid_device *hid, struct hid_report *rep,
int reqtype)
{
@@ -761,6 +783,8 @@ static struct hid_ll_driver i2c_hid_ll_driver = {
.close = i2c_hid_close,
.power = i2c_hid_power,
.request = i2c_hid_request,
+ .output_report = i2c_hid_output_report,
+ .raw_request = i2c_hid_raw_request,
};
static int i2c_hid_init_irq(struct i2c_client *client)
--
1.8.3.1
^ permalink raw reply related
* [PATCH 05/11] HID: HIDp: remove hidp_hidinput_event
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
hidp uses its own ->hidinput_input_event() instead of the generic binding
in hid-input.
Moving the handling of LEDs towards hidp_hidinput_event() allows two things:
- remove hidinput_input_event definitively from struct hid_device
- hidraw user space programs can also set the LEDs
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
net/bluetooth/hidp/core.c | 46 ----------------------------------------------
1 file changed, 46 deletions(-)
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c
index b062cee..469e61b 100644
--- a/net/bluetooth/hidp/core.c
+++ b/net/bluetooth/hidp/core.c
@@ -223,51 +223,6 @@ static void hidp_input_report(struct hidp_session *session, struct sk_buff *skb)
input_sync(dev);
}
-static int hidp_send_report(struct hidp_session *session, struct hid_report *report)
-{
- unsigned char hdr;
- u8 *buf;
- int rsize, ret;
-
- buf = hid_alloc_report_buf(report, GFP_ATOMIC);
- if (!buf)
- return -EIO;
-
- hid_output_report(report, buf);
- hdr = HIDP_TRANS_DATA | HIDP_DATA_RTYPE_OUPUT;
-
- rsize = ((report->size - 1) >> 3) + 1 + (report->id > 0);
- ret = hidp_send_intr_message(session, hdr, buf, rsize);
-
- kfree(buf);
- return ret;
-}
-
-static int hidp_hidinput_event(struct input_dev *dev, unsigned int type,
- unsigned int code, int value)
-{
- struct hid_device *hid = input_get_drvdata(dev);
- struct hidp_session *session = hid->driver_data;
- struct hid_field *field;
- int offset;
-
- BT_DBG("session %p type %d code %d value %d",
- session, type, code, value);
-
- if (type != EV_LED)
- return -1;
-
- offset = hidinput_find_field(hid, type, code, &field);
- if (offset == -1) {
- hid_warn(dev, "event field not found\n");
- return -1;
- }
-
- hid_set_field(field, offset, value);
-
- return hidp_send_report(session, field->report);
-}
-
static int hidp_get_raw_report(struct hid_device *hid,
unsigned char report_number,
unsigned char *data, size_t count,
@@ -817,7 +772,6 @@ static struct hid_ll_driver hidp_hid_driver = {
.close = hidp_close,
.raw_request = hidp_raw_request,
.output_report = hidp_output_report,
- .hidinput_input_event = hidp_hidinput_event,
};
/* This function sets up the hid device. It does not add it
--
1.8.3.1
^ permalink raw reply related
* [PATCH 07/11] HID: HIDp: remove duplicated coded
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
- Move hidp_output_report() above
- Removed duplicated code in hidp_output_raw_report()
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
net/bluetooth/hidp/core.c | 68 ++++++++---------------------------------------
1 file changed, 11 insertions(+), 57 deletions(-)
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c
index 469e61b..02670b3 100644
--- a/net/bluetooth/hidp/core.c
+++ b/net/bluetooth/hidp/core.c
@@ -373,62 +373,25 @@ err:
return ret;
}
-static int hidp_output_raw_report(struct hid_device *hid, unsigned char *data, size_t count,
- unsigned char report_type)
+static int hidp_output_report(struct hid_device *hid, __u8 *data, size_t count)
{
struct hidp_session *session = hid->driver_data;
- int ret;
+ return hidp_send_intr_message(session,
+ HIDP_TRANS_DATA | HIDP_DATA_RTYPE_OUPUT,
+ data, count);
+}
+
+static int hidp_output_raw_report(struct hid_device *hid, unsigned char *data,
+ size_t count, unsigned char report_type)
+{
if (report_type == HID_OUTPUT_REPORT) {
- report_type = HIDP_TRANS_DATA | HIDP_DATA_RTYPE_OUPUT;
- return hidp_send_intr_message(session, report_type,
- data, count);
+ return hidp_output_report(hid, data, count);
} else if (report_type != HID_FEATURE_REPORT) {
return -EINVAL;
}
- if (mutex_lock_interruptible(&session->report_mutex))
- return -ERESTARTSYS;
-
- /* Set up our wait, and send the report request to the device. */
- set_bit(HIDP_WAITING_FOR_SEND_ACK, &session->flags);
- report_type = HIDP_TRANS_SET_REPORT | HIDP_DATA_RTYPE_FEATURE;
- ret = hidp_send_ctrl_message(session, report_type, data, count);
- if (ret)
- goto err;
-
- /* Wait for the ACK from the device. */
- while (test_bit(HIDP_WAITING_FOR_SEND_ACK, &session->flags) &&
- !atomic_read(&session->terminate)) {
- int res;
-
- res = wait_event_interruptible_timeout(session->report_queue,
- !test_bit(HIDP_WAITING_FOR_SEND_ACK, &session->flags)
- || atomic_read(&session->terminate),
- 10*HZ);
- if (res == 0) {
- /* timeout */
- ret = -EIO;
- goto err;
- }
- if (res < 0) {
- /* signal */
- ret = -ERESTARTSYS;
- goto err;
- }
- }
-
- if (!session->output_report_success) {
- ret = -EIO;
- goto err;
- }
-
- ret = count;
-
-err:
- clear_bit(HIDP_WAITING_FOR_SEND_ACK, &session->flags);
- mutex_unlock(&session->report_mutex);
- return ret;
+ return hidp_set_raw_report(hid, data[0], data, count, report_type);
}
static int hidp_raw_request(struct hid_device *hid, unsigned char reportnum,
@@ -445,15 +408,6 @@ static int hidp_raw_request(struct hid_device *hid, unsigned char reportnum,
}
}
-static int hidp_output_report(struct hid_device *hid, __u8 *data, size_t count)
-{
- struct hidp_session *session = hid->driver_data;
-
- return hidp_send_intr_message(session,
- HIDP_TRANS_DATA | HIDP_DATA_RTYPE_OUPUT,
- data, count);
-}
-
static void hidp_idle_timeout(unsigned long arg)
{
struct hidp_session *session = (struct hidp_session *) arg;
--
1.8.3.1
^ permalink raw reply related
* [PATCH 08/11] HID: usbhid: remove duplicated code
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
Well, no use to keep twice the same code.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/usbhid/hid-core.c | 64 ++++++++-----------------------------------
1 file changed, 11 insertions(+), 53 deletions(-)
diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
index f8ca312..406497b 100644
--- a/drivers/hid/usbhid/hid-core.c
+++ b/drivers/hid/usbhid/hid-core.c
@@ -915,59 +915,6 @@ static int usbhid_set_raw_report(struct hid_device *hid, unsigned int reportnum,
return ret;
}
-
-static int usbhid_output_raw_report(struct hid_device *hid, __u8 *buf, size_t count,
- unsigned char report_type)
-{
- struct usbhid_device *usbhid = hid->driver_data;
- struct usb_device *dev = hid_to_usb_dev(hid);
- struct usb_interface *intf = usbhid->intf;
- struct usb_host_interface *interface = intf->cur_altsetting;
- int ret;
-
- if (usbhid->urbout && report_type != HID_FEATURE_REPORT) {
- int actual_length;
- int skipped_report_id = 0;
-
- if (buf[0] == 0x0) {
- /* Don't send the Report ID */
- buf++;
- count--;
- skipped_report_id = 1;
- }
- ret = usb_interrupt_msg(dev, usbhid->urbout->pipe,
- buf, count, &actual_length,
- USB_CTRL_SET_TIMEOUT);
- /* return the number of bytes transferred */
- if (ret == 0) {
- ret = actual_length;
- /* count also the report id */
- if (skipped_report_id)
- ret++;
- }
- } else {
- int skipped_report_id = 0;
- int report_id = buf[0];
- if (buf[0] == 0x0) {
- /* Don't send the Report ID */
- buf++;
- count--;
- skipped_report_id = 1;
- }
- ret = usb_control_msg(dev, usb_sndctrlpipe(dev, 0),
- HID_REQ_SET_REPORT,
- USB_DIR_OUT | USB_TYPE_CLASS | USB_RECIP_INTERFACE,
- ((report_type + 1) << 8) | report_id,
- interface->desc.bInterfaceNumber, buf, count,
- USB_CTRL_SET_TIMEOUT);
- /* count also the report id, if this was a numbered report. */
- if (ret > 0 && skipped_report_id)
- ret++;
- }
-
- return ret;
-}
-
static int usbhid_output_report(struct hid_device *hid, __u8 *buf, size_t count)
{
struct usbhid_device *usbhid = hid->driver_data;
@@ -998,6 +945,17 @@ static int usbhid_output_report(struct hid_device *hid, __u8 *buf, size_t count)
return ret;
}
+static int usbhid_output_raw_report(struct hid_device *hid, __u8 *buf,
+ size_t count, unsigned char report_type)
+{
+ struct usbhid_device *usbhid = hid->driver_data;
+
+ if (usbhid->urbout && report_type != HID_FEATURE_REPORT)
+ return usbhid_output_report(hid, buf, count);
+
+ return usbhid_set_raw_report(hid, buf[0], buf, count, report_type);
+}
+
static void usbhid_restart_queues(struct usbhid_device *usbhid)
{
if (usbhid->urbout && !test_bit(HID_OUT_RUNNING, &usbhid->iofl))
--
1.8.3.1
^ permalink raw reply related
* [PATCH 09/11] HID: remove hid_get_raw_report in struct hid_device
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
dev->hid_get_raw_report(X) and hid_hw_raw_request(X, HID_REQ_GET_REPORT)
are strictly equivalent. Switch the hid subsystem to the hid_hw notation
and remove the field .hid_get_raw_report in struct hid_device.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/hid-input.c | 6 +++---
drivers/hid/hid-sony.c | 3 ++-
drivers/hid/hidraw.c | 7 ++++---
drivers/hid/i2c-hid/i2c-hid.c | 1 -
drivers/hid/uhid.c | 1 -
drivers/hid/usbhid/hid-core.c | 1 -
include/linux/hid.h | 3 ---
net/bluetooth/hidp/core.c | 1 -
8 files changed, 9 insertions(+), 14 deletions(-)
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index 594722d..1de5997 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -350,9 +350,9 @@ static int hidinput_get_battery_property(struct power_supply *psy,
ret = -ENOMEM;
break;
}
- ret = dev->hid_get_raw_report(dev, dev->battery_report_id,
- buf, 2,
- dev->battery_report_type);
+ ret = hid_hw_raw_request(dev, dev->battery_report_id, buf, 2,
+ dev->battery_report_type,
+ HID_REQ_GET_REPORT);
if (ret != 2) {
ret = -ENODATA;
diff --git a/drivers/hid/hid-sony.c b/drivers/hid/hid-sony.c
index 1235405..3930acb 100644
--- a/drivers/hid/hid-sony.c
+++ b/drivers/hid/hid-sony.c
@@ -706,7 +706,8 @@ static int sixaxis_set_operational_usb(struct hid_device *hdev)
if (!buf)
return -ENOMEM;
- ret = hdev->hid_get_raw_report(hdev, 0xf2, buf, 17, HID_FEATURE_REPORT);
+ ret = hid_hw_raw_request(hdev, 0xf2, buf, 17, HID_FEATURE_REPORT,
+ HID_REQ_GET_REPORT);
if (ret < 0)
hid_err(hdev, "can't set operational mode\n");
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c
index cb0137b..4b2dc95 100644
--- a/drivers/hid/hidraw.c
+++ b/drivers/hid/hidraw.c
@@ -189,7 +189,7 @@ static ssize_t hidraw_get_report(struct file *file, char __user *buffer, size_t
dev = hidraw_table[minor]->hid;
- if (!dev->hid_get_raw_report) {
+ if (!dev->ll_driver->raw_request) {
ret = -ENODEV;
goto out;
}
@@ -216,14 +216,15 @@ static ssize_t hidraw_get_report(struct file *file, char __user *buffer, size_t
/*
* Read the first byte from the user. This is the report number,
- * which is passed to dev->hid_get_raw_report().
+ * which is passed to hid_hw_raw_request().
*/
if (copy_from_user(&report_number, buffer, 1)) {
ret = -EFAULT;
goto out_free;
}
- ret = dev->hid_get_raw_report(dev, report_number, buf, count, report_type);
+ ret = hid_hw_raw_request(dev, report_number, buf, count, report_type,
+ HID_REQ_GET_REPORT);
if (ret < 0)
goto out_free;
diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c
index 5099f1f..fe3b392 100644
--- a/drivers/hid/i2c-hid/i2c-hid.c
+++ b/drivers/hid/i2c-hid/i2c-hid.c
@@ -1029,7 +1029,6 @@ static int i2c_hid_probe(struct i2c_client *client,
hid->driver_data = client;
hid->ll_driver = &i2c_hid_ll_driver;
- hid->hid_get_raw_report = i2c_hid_get_raw_report;
hid->hid_output_raw_report = i2c_hid_output_raw_report;
hid->dev.parent = &client->dev;
ACPI_COMPANION_SET(&hid->dev, ACPI_COMPANION(&client->dev));
diff --git a/drivers/hid/uhid.c b/drivers/hid/uhid.c
index 438c9f1..7358346 100644
--- a/drivers/hid/uhid.c
+++ b/drivers/hid/uhid.c
@@ -421,7 +421,6 @@ static int uhid_dev_create(struct uhid_device *uhid,
hid->uniq[63] = 0;
hid->ll_driver = &uhid_hid_driver;
- hid->hid_get_raw_report = uhid_hid_get_raw;
hid->hid_output_raw_report = uhid_hid_output_raw;
hid->bus = ev->u.create.bus;
hid->vendor = ev->u.create.vendor;
diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
index 406497b..b9a770f 100644
--- a/drivers/hid/usbhid/hid-core.c
+++ b/drivers/hid/usbhid/hid-core.c
@@ -1289,7 +1289,6 @@ static int usbhid_probe(struct usb_interface *intf, const struct usb_device_id *
usb_set_intfdata(intf, hid);
hid->ll_driver = &usb_hid_driver;
- hid->hid_get_raw_report = usbhid_get_raw_report;
hid->hid_output_raw_report = usbhid_output_raw_report;
hid->ff_init = hid_pidff_init;
#ifdef CONFIG_USB_HIDDEV
diff --git a/include/linux/hid.h b/include/linux/hid.h
index 38c307b..c56681a 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -508,9 +508,6 @@ struct hid_device { /* device report descriptor */
struct hid_usage *, __s32);
void (*hiddev_report_event) (struct hid_device *, struct hid_report *);
- /* handler for raw input (Get_Report) data, used by hidraw */
- int (*hid_get_raw_report) (struct hid_device *, unsigned char, __u8 *, size_t, unsigned char);
-
/* handler for raw output data, used by hidraw */
int (*hid_output_raw_report) (struct hid_device *, __u8 *, size_t, unsigned char);
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c
index 02670b3..77c4bad 100644
--- a/net/bluetooth/hidp/core.c
+++ b/net/bluetooth/hidp/core.c
@@ -773,7 +773,6 @@ static int hidp_setup_hid(struct hidp_session *session,
hid->dev.parent = &session->conn->hcon->dev;
hid->ll_driver = &hidp_hid_driver;
- hid->hid_get_raw_report = hidp_get_raw_report;
hid->hid_output_raw_report = hidp_output_raw_report;
/* True if device is blacklisted in drivers/hid/hid-core.c */
--
1.8.3.1
^ permalink raw reply related
* [PATCH 11/11] HID: move hid_output_raw_report to hid_ll_driver
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
struct hid_ll_driver is responsible for the transport communication.
Move hid_output_raw_report from hid_device to the transport layer then.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/hid-input.c | 2 +-
drivers/hid/hid-logitech-dj.c | 2 +-
drivers/hid/hid-sony.c | 11 ++++++++++-
drivers/hid/hid-wiimote-core.c | 2 +-
drivers/hid/hidraw.c | 2 +-
drivers/hid/i2c-hid/i2c-hid.c | 2 +-
drivers/hid/uhid.c | 2 +-
drivers/hid/usbhid/hid-core.c | 2 +-
include/linux/hid.h | 11 +++++++----
net/bluetooth/hidp/core.c | 4 ++--
10 files changed, 26 insertions(+), 14 deletions(-)
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index 78293c3..3125155 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -1263,7 +1263,7 @@ static struct hid_input *hidinput_allocate(struct hid_device *hid)
}
input_set_drvdata(input_dev, hid);
- if (hid->ll_driver->request || hid->hid_output_raw_report)
+ if (hid->ll_driver->request || hid->ll_driver->hid_output_raw_report)
input_dev->event = hidinput_input_event;
input_dev->open = hidinput_open;
input_dev->close = hidinput_close;
diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c
index 9347625..bdfa1db 100644
--- a/drivers/hid/hid-logitech-dj.c
+++ b/drivers/hid/hid-logitech-dj.c
@@ -262,7 +262,6 @@ static void logi_dj_recv_add_djhid_device(struct dj_receiver_dev *djrcv_dev,
}
dj_hiddev->ll_driver = &logi_dj_ll_driver;
- dj_hiddev->hid_output_raw_report = logi_dj_output_hidraw_report;
dj_hiddev->dev.parent = &djrcv_hdev->dev;
dj_hiddev->bus = BUS_USB;
@@ -655,6 +654,7 @@ static struct hid_ll_driver logi_dj_ll_driver = {
.stop = logi_dj_ll_stop,
.open = logi_dj_ll_open,
.close = logi_dj_ll_close,
+ .hid_output_raw_report = logi_dj_output_hidraw_report,
};
diff --git a/drivers/hid/hid-sony.c b/drivers/hid/hid-sony.c
index 8494b8c..9dd37ff 100644
--- a/drivers/hid/hid-sony.c
+++ b/drivers/hid/hid-sony.c
@@ -494,6 +494,8 @@ struct sony_sc {
unsigned long quirks;
struct work_struct state_worker;
+ struct hid_ll_driver *ll_driver;
+
#ifdef CONFIG_SONY_FF
__u8 left;
__u8 right;
@@ -1077,7 +1079,14 @@ static int sony_probe(struct hid_device *hdev, const struct hid_device_id *id)
}
if (sc->quirks & SIXAXIS_CONTROLLER_USB) {
- hdev->hid_output_raw_report = sixaxis_usb_output_raw_report;
+ sc->ll_driver = devm_kzalloc(&hdev->dev, sizeof(*sc->ll_driver),
+ GFP_KERNEL);
+ if (sc->ll_driver == NULL)
+ return -ENOMEM;
+ *sc->ll_driver = *hdev->ll_driver;
+ hdev->ll_driver = sc->ll_driver;
+ sc->ll_driver->hid_output_raw_report =
+ sixaxis_usb_output_raw_report;
ret = sixaxis_set_operational_usb(hdev);
INIT_WORK(&sc->state_worker, sixaxis_state_worker);
}
diff --git a/drivers/hid/hid-wiimote-core.c b/drivers/hid/hid-wiimote-core.c
index d7dc6c5b..715a3ab 100644
--- a/drivers/hid/hid-wiimote-core.c
+++ b/drivers/hid/hid-wiimote-core.c
@@ -28,7 +28,7 @@ static int wiimote_hid_send(struct hid_device *hdev, __u8 *buffer,
__u8 *buf;
int ret;
- if (!hdev->hid_output_raw_report)
+ if (!hdev->ll_driver->hid_output_raw_report)
return -ENODEV;
buf = kmemdup(buffer, count, GFP_KERNEL);
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c
index f8708c9..c60c530 100644
--- a/drivers/hid/hidraw.c
+++ b/drivers/hid/hidraw.c
@@ -123,7 +123,7 @@ static ssize_t hidraw_send_report(struct file *file, const char __user *buffer,
dev = hidraw_table[minor]->hid;
- if (!dev->hid_output_raw_report) {
+ if (!dev->ll_driver->hid_output_raw_report) {
ret = -ENODEV;
goto out;
}
diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c
index fe3b392..fabb388 100644
--- a/drivers/hid/i2c-hid/i2c-hid.c
+++ b/drivers/hid/i2c-hid/i2c-hid.c
@@ -785,6 +785,7 @@ static struct hid_ll_driver i2c_hid_ll_driver = {
.request = i2c_hid_request,
.output_report = i2c_hid_output_report,
.raw_request = i2c_hid_raw_request,
+ .hid_output_raw_report = i2c_hid_output_raw_report,
};
static int i2c_hid_init_irq(struct i2c_client *client)
@@ -1029,7 +1030,6 @@ static int i2c_hid_probe(struct i2c_client *client,
hid->driver_data = client;
hid->ll_driver = &i2c_hid_ll_driver;
- hid->hid_output_raw_report = i2c_hid_output_raw_report;
hid->dev.parent = &client->dev;
ACPI_COMPANION_SET(&hid->dev, ACPI_COMPANION(&client->dev));
hid->bus = BUS_I2C;
diff --git a/drivers/hid/uhid.c b/drivers/hid/uhid.c
index 7358346..8e99a5a 100644
--- a/drivers/hid/uhid.c
+++ b/drivers/hid/uhid.c
@@ -294,6 +294,7 @@ static struct hid_ll_driver uhid_hid_driver = {
.parse = uhid_hid_parse,
.output_report = uhid_hid_output_report,
.raw_request = uhid_raw_request,
+ .hid_output_raw_report = uhid_hid_output_raw,
};
#ifdef CONFIG_COMPAT
@@ -421,7 +422,6 @@ static int uhid_dev_create(struct uhid_device *uhid,
hid->uniq[63] = 0;
hid->ll_driver = &uhid_hid_driver;
- hid->hid_output_raw_report = uhid_hid_output_raw;
hid->bus = ev->u.create.bus;
hid->vendor = ev->u.create.vendor;
hid->product = ev->u.create.product;
diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
index b9a770f..9c3c244 100644
--- a/drivers/hid/usbhid/hid-core.c
+++ b/drivers/hid/usbhid/hid-core.c
@@ -1260,6 +1260,7 @@ static struct hid_ll_driver usb_hid_driver = {
.raw_request = usbhid_raw_request,
.output_report = usbhid_output_report,
.idle = usbhid_idle,
+ .hid_output_raw_report = usbhid_output_raw_report,
};
static int usbhid_probe(struct usb_interface *intf, const struct usb_device_id *id)
@@ -1289,7 +1290,6 @@ static int usbhid_probe(struct usb_interface *intf, const struct usb_device_id *
usb_set_intfdata(intf, hid);
hid->ll_driver = &usb_hid_driver;
- hid->hid_output_raw_report = usbhid_output_raw_report;
hid->ff_init = hid_pidff_init;
#ifdef CONFIG_USB_HIDDEV
hid->hiddev_connect = hiddev_connect;
diff --git a/include/linux/hid.h b/include/linux/hid.h
index a837ede..eb588e9 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -508,9 +508,6 @@ struct hid_device { /* device report descriptor */
struct hid_usage *, __s32);
void (*hiddev_report_event) (struct hid_device *, struct hid_report *);
- /* handler for raw output data, used by hidraw */
- int (*hid_output_raw_report) (struct hid_device *, __u8 *, size_t, unsigned char);
-
/* debugging support via debugfs */
unsigned short debug;
struct dentry *debug_dir;
@@ -678,6 +675,7 @@ struct hid_driver {
* @wait: wait for buffered io to complete (send/recv reports)
* @raw_request: send raw report request to device (e.g. feature report)
* @output_report: send output report to device
+ * @hid_output_raw_report: send report to device (e.g. feature report)
* @idle: send idle request to device
*/
struct hid_ll_driver {
@@ -702,6 +700,10 @@ struct hid_ll_driver {
int (*output_report) (struct hid_device *hdev, __u8 *buf, size_t len);
+ /* handler for raw output data, used by hidraw */
+ int (*hid_output_raw_report) (struct hid_device *, __u8 *, size_t,
+ unsigned char);
+
int (*idle)(struct hid_device *hdev, int report, int idle, int reqtype);
};
@@ -1024,7 +1026,8 @@ static inline int hid_hw_output_report(struct hid_device *hdev, __u8 *buf,
static inline int hid_output_raw_report(struct hid_device *hdev, __u8 *buf,
size_t len, unsigned char report_type)
{
- return hdev->hid_output_raw_report(hdev, buf, len, report_type);
+ return hdev->ll_driver->hid_output_raw_report(hdev, buf, len,
+ report_type);
}
/**
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c
index 77c4bad..6189b54 100644
--- a/net/bluetooth/hidp/core.c
+++ b/net/bluetooth/hidp/core.c
@@ -726,6 +726,8 @@ static struct hid_ll_driver hidp_hid_driver = {
.close = hidp_close,
.raw_request = hidp_raw_request,
.output_report = hidp_output_report,
+ .hid_output_raw_report = hidp_output_raw_report,
+
};
/* This function sets up the hid device. It does not add it
@@ -773,8 +775,6 @@ static int hidp_setup_hid(struct hidp_session *session,
hid->dev.parent = &session->conn->hcon->dev;
hid->ll_driver = &hidp_hid_driver;
- hid->hid_output_raw_report = hidp_output_raw_report;
-
/* True if device is blacklisted in drivers/hid/hid-core.c */
if (hid_ignore(hid)) {
hid_destroy_device(session->hid);
--
1.8.3.1
^ permalink raw reply related
* [PATCH 00/11] HID: spring cleaning
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
Hi guys,
This is an attempt to complete the branch for-3.15/ll-driver-new-callbacks:
- try to implement as much as possible ll_driver callbacks (some are still
missing, but I did not had the time to complete it)
- add inliners hid_hw_* for all the ll_driver callbacks
- remove transport dependant callbacks in struct hid_device
- remove the so called "obsolete" hidinput_input_event handler which was used
in 2/4 transport drivers
Bonus point: 14 files changed, 213 insertions(+), 272 deletions(-)
Yay!
I made sure I kept the PS3 controller working and the LEDs (on logitech-dj and
on bluetooth keyboard) working. The rest do not mostly need further testing,
the code path did not changed. But still, a review (and some tests) would be a
good idea :)
Cheers,
Benjamin
PS: obviously, this goes on top on the branch for-3.15/ll-driver-new-callbacks
Benjamin Tissoires (11):
HID: uHID: implement .raw_request
HID: i2c-hid: implement ll_driver transport-layer callbacks
HID: add inliners for ll_driver transport-layer callbacks
HID: logitech-dj: remove hidinput_input_event
HID: HIDp: remove hidp_hidinput_event
HID: remove hidinput_input_event handler
HID: HIDp: remove duplicated coded
HID: usbhid: remove duplicated code
HID: remove hid_get_raw_report in struct hid_device
HID: introduce helper to access hid_output_raw_report()
HID: move hid_output_raw_report to hid_ll_driver
drivers/hid/hid-input.c | 12 ++---
drivers/hid/hid-lg.c | 6 ++-
drivers/hid/hid-logitech-dj.c | 101 +++++++++++++---------------------
drivers/hid/hid-magicmouse.c | 2 +-
drivers/hid/hid-sony.c | 19 +++++--
drivers/hid/hid-thingm.c | 4 +-
drivers/hid/hid-wacom.c | 16 +++---
drivers/hid/hid-wiimote-core.c | 4 +-
drivers/hid/hidraw.c | 11 ++--
drivers/hid/i2c-hid/i2c-hid.c | 27 +++++++++-
drivers/hid/uhid.c | 20 ++++++-
drivers/hid/usbhid/hid-core.c | 67 +++++------------------
include/linux/hid.h | 77 ++++++++++++++++++++++----
net/bluetooth/hidp/core.c | 119 +++++------------------------------------
14 files changed, 213 insertions(+), 272 deletions(-)
--
1.8.3.1
^ permalink raw reply
* [PATCH 04/11] HID: logitech-dj: remove hidinput_input_event
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
hid-logitech-dj uses its own ->hidinput_input_event() instead of
the generic binding in hid-input.
Moving the handling of LEDs towards logi_dj_output_hidraw_report()
allows two things:
- remove hidinput_input_event in struct hid_device
- hidraw user space programs can also set the LEDs
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/hid-logitech-dj.c | 99 +++++++++++++++----------------------------
1 file changed, 35 insertions(+), 64 deletions(-)
diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c
index f45279c..61d2bbf 100644
--- a/drivers/hid/hid-logitech-dj.c
+++ b/drivers/hid/hid-logitech-dj.c
@@ -44,14 +44,6 @@ static const char kbd_descriptor[] = {
0x19, 0xE0, /* USAGE_MINIMUM (Left Control) */
0x29, 0xE7, /* USAGE_MAXIMUM (Right GUI) */
0x81, 0x02, /* INPUT (Data,Var,Abs) */
- 0x95, 0x05, /* REPORT COUNT (5) */
- 0x05, 0x08, /* USAGE PAGE (LED page) */
- 0x19, 0x01, /* USAGE MINIMUM (1) */
- 0x29, 0x05, /* USAGE MAXIMUM (5) */
- 0x91, 0x02, /* OUTPUT (Data, Variable, Absolute) */
- 0x95, 0x01, /* REPORT COUNT (1) */
- 0x75, 0x03, /* REPORT SIZE (3) */
- 0x91, 0x01, /* OUTPUT (Constant) */
0x95, 0x06, /* REPORT_COUNT (6) */
0x75, 0x08, /* REPORT_SIZE (8) */
0x15, 0x00, /* LOGICAL_MINIMUM (0) */
@@ -60,6 +52,18 @@ static const char kbd_descriptor[] = {
0x19, 0x00, /* USAGE_MINIMUM (no event) */
0x2A, 0xFF, 0x00, /* USAGE_MAXIMUM (reserved) */
0x81, 0x00, /* INPUT (Data,Ary,Abs) */
+ 0x85, 0x0e, /* REPORT_ID (14) */
+ 0x05, 0x08, /* USAGE PAGE (LED page) */
+ 0x95, 0x05, /* REPORT COUNT (5) */
+ 0x75, 0x01, /* REPORT SIZE (1) */
+ 0x15, 0x00, /* LOGICAL_MINIMUM (0) */
+ 0x25, 0x01, /* LOGICAL_MAXIMUM (1) */
+ 0x19, 0x01, /* USAGE MINIMUM (1) */
+ 0x29, 0x05, /* USAGE MAXIMUM (5) */
+ 0x91, 0x02, /* OUTPUT (Data, Variable, Absolute) */
+ 0x95, 0x01, /* REPORT COUNT (1) */
+ 0x75, 0x03, /* REPORT SIZE (3) */
+ 0x91, 0x01, /* OUTPUT (Constant) */
0xC0
};
@@ -544,10 +548,30 @@ static int logi_dj_output_hidraw_report(struct hid_device *hid, u8 * buf,
size_t count,
unsigned char report_type)
{
- /* Called by hid raw to send data */
- dbg_hid("%s\n", __func__);
+ struct dj_device *djdev = hid->driver_data;
+ struct dj_receiver_dev *djrcv_dev = djdev->dj_receiver_dev;
+ u8 *out_buf;
+ int ret;
- return 0;
+ if (buf[0] != REPORT_TYPE_LEDS)
+ return -EINVAL;
+
+ out_buf = kzalloc(DJREPORT_SHORT_LENGTH, GFP_ATOMIC);
+ if (!out_buf)
+ return -ENOMEM;
+
+ if (count < DJREPORT_SHORT_LENGTH - 2)
+ count = DJREPORT_SHORT_LENGTH - 2;
+
+ out_buf[0] = REPORT_ID_DJ_SHORT;
+ out_buf[1] = djdev->device_index;
+ memcpy(out_buf + 2, buf, count);
+
+ ret = djrcv_dev->hdev->hid_output_raw_report(djrcv_dev->hdev, out_buf,
+ DJREPORT_SHORT_LENGTH, report_type);
+
+ kfree(out_buf);
+ return ret;
}
static void rdcat(char *rdesc, unsigned int *rsize, const char *data, unsigned int size)
@@ -613,58 +637,6 @@ static int logi_dj_ll_parse(struct hid_device *hid)
return retval;
}
-static int logi_dj_ll_input_event(struct input_dev *dev, unsigned int type,
- unsigned int code, int value)
-{
- /* Sent by the input layer to handle leds and Force Feedback */
- struct hid_device *dj_hiddev = input_get_drvdata(dev);
- struct dj_device *dj_dev = dj_hiddev->driver_data;
-
- struct dj_receiver_dev *djrcv_dev =
- dev_get_drvdata(dj_hiddev->dev.parent);
- struct hid_device *dj_rcv_hiddev = djrcv_dev->hdev;
- struct hid_report_enum *output_report_enum;
-
- struct hid_field *field;
- struct hid_report *report;
- unsigned char *data;
- int offset;
-
- dbg_hid("%s: %s, type:%d | code:%d | value:%d\n",
- __func__, dev->phys, type, code, value);
-
- if (type != EV_LED)
- return -1;
-
- offset = hidinput_find_field(dj_hiddev, type, code, &field);
-
- if (offset == -1) {
- dev_warn(&dev->dev, "event field not found\n");
- return -1;
- }
- hid_set_field(field, offset, value);
-
- data = hid_alloc_report_buf(field->report, GFP_ATOMIC);
- if (!data) {
- dev_warn(&dev->dev, "failed to allocate report buf memory\n");
- return -1;
- }
-
- hid_output_report(field->report, &data[0]);
-
- output_report_enum = &dj_rcv_hiddev->report_enum[HID_OUTPUT_REPORT];
- report = output_report_enum->report_id_hash[REPORT_ID_DJ_SHORT];
- hid_set_field(report->field[0], 0, dj_dev->device_index);
- hid_set_field(report->field[0], 1, REPORT_TYPE_LEDS);
- hid_set_field(report->field[0], 2, data[1]);
-
- hid_hw_request(dj_rcv_hiddev, report, HID_REQ_SET_REPORT);
-
- kfree(data);
-
- return 0;
-}
-
static int logi_dj_ll_start(struct hid_device *hid)
{
dbg_hid("%s\n", __func__);
@@ -683,7 +655,6 @@ static struct hid_ll_driver logi_dj_ll_driver = {
.stop = logi_dj_ll_stop,
.open = logi_dj_ll_open,
.close = logi_dj_ll_close,
- .hidinput_input_event = logi_dj_ll_input_event,
};
--
1.8.3.1
^ permalink raw reply related
* [PATCH 03/11] HID: add inliners for ll_driver transport-layer callbacks
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
Those callbacks are not mandatory, so it's better to add inliners
to use them safely.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
include/linux/hid.h | 45 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 45 insertions(+)
diff --git a/include/linux/hid.h b/include/linux/hid.h
index 003cc8e..dddcad0 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -680,6 +680,8 @@ struct hid_driver {
* shouldn't allocate anything to not leak memory
* @request: send report request to device (e.g. feature report)
* @wait: wait for buffered io to complete (send/recv reports)
+ * @raw_request: send raw report request to device (e.g. feature report)
+ * @output_report: send output report to device
* @idle: send idle request to device
*/
struct hid_ll_driver {
@@ -974,6 +976,49 @@ static inline void hid_hw_request(struct hid_device *hdev,
}
/**
+ * hid_hw_raw_request - send report request to device
+ *
+ * @hdev: hid device
+ * @reportnum: report ID
+ * @buf: in/out data to transfer
+ * @len: length of buf
+ * @rtype: HID report type
+ * @reqtype: HID_REQ_GET_REPORT or HID_REQ_SET_REPORT
+ *
+ * @return: count of data transfered, negative if error
+ *
+ * Same behavior as hid_hw_request, but with raw buffers instead.
+ */
+static inline int hid_hw_raw_request(struct hid_device *hdev,
+ unsigned char reportnum, __u8 *buf,
+ size_t len, unsigned char rtype, int reqtype)
+{
+ if (hdev->ll_driver->raw_request)
+ return hdev->ll_driver->raw_request(hdev, reportnum, buf, len,
+ rtype, reqtype);
+
+ return -ENOSYS;
+}
+
+/**
+ * hid_hw_output_report - send output report to device
+ *
+ * @hdev: hid device
+ * @buf: raw data to transfer
+ * @len: length of buf
+ *
+ * @return: count of data transfered, negative if error
+ */
+static inline int hid_hw_output_report(struct hid_device *hdev, __u8 *buf,
+ size_t len)
+{
+ if (hdev->ll_driver->output_report)
+ return hdev->ll_driver->output_report(hdev, buf, len);
+
+ return -ENOSYS;
+}
+
+/**
* hid_hw_idle - send idle request to device
*
* @hdev: hid device
--
1.8.3.1
^ permalink raw reply related
* [PATCH 06/11] HID: remove hidinput_input_event handler
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
All the different transport drivers use now the generic event handling
in hid-input. We can remove the handler definitively now.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/hid-input.c | 4 +---
include/linux/hid.h | 4 ----
2 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index a713e62..594722d 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -1263,9 +1263,7 @@ static struct hid_input *hidinput_allocate(struct hid_device *hid)
}
input_set_drvdata(input_dev, hid);
- if (hid->ll_driver->hidinput_input_event)
- input_dev->event = hid->ll_driver->hidinput_input_event;
- else if (hid->ll_driver->request || hid->hid_output_raw_report)
+ if (hid->ll_driver->request || hid->hid_output_raw_report)
input_dev->event = hidinput_input_event;
input_dev->open = hidinput_open;
input_dev->close = hidinput_close;
diff --git a/include/linux/hid.h b/include/linux/hid.h
index dddcad0..38c307b 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -675,7 +675,6 @@ struct hid_driver {
* @stop: called on remove
* @open: called by input layer on open
* @close: called by input layer on close
- * @hidinput_input_event: event input event (e.g. ff or leds)
* @parse: this method is called only once to parse the device data,
* shouldn't allocate anything to not leak memory
* @request: send report request to device (e.g. feature report)
@@ -693,9 +692,6 @@ struct hid_ll_driver {
int (*power)(struct hid_device *hdev, int level);
- int (*hidinput_input_event) (struct input_dev *idev, unsigned int type,
- unsigned int code, int value);
-
int (*parse)(struct hid_device *hdev);
void (*request)(struct hid_device *hdev,
--
1.8.3.1
^ permalink raw reply related
* [PATCH 10/11] HID: introduce helper to access hid_output_raw_report()
From: Benjamin Tissoires @ 2014-02-02 4:50 UTC (permalink / raw)
To: Benjamin Tissoires, Jiri Kosina, David Herrmann, Frank Praznik,
linux-input, linux-kernel
In-Reply-To: <1391316630-29541-1-git-send-email-benjamin.tissoires@redhat.com>
Add a helper to access hdev->hid_output_raw_report().
To convert the drivers, use the following snippets:
for i in drivers/hid/*.c
do
sed -i.bak "s/[^ \t]*->hid_output_raw_report(/hid_output_raw_report(/g" $i
done
Then manually fix for checkpatch.pl
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
---
drivers/hid/hid-input.c | 2 +-
drivers/hid/hid-lg.c | 6 ++++--
drivers/hid/hid-logitech-dj.c | 2 +-
drivers/hid/hid-magicmouse.c | 2 +-
drivers/hid/hid-sony.c | 5 +++--
drivers/hid/hid-thingm.c | 4 ++--
drivers/hid/hid-wacom.c | 16 +++++++---------
drivers/hid/hid-wiimote-core.c | 2 +-
drivers/hid/hidraw.c | 2 +-
include/linux/hid.h | 16 ++++++++++++++++
10 files changed, 37 insertions(+), 20 deletions(-)
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index 1de5997..78293c3 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -1184,7 +1184,7 @@ static void hidinput_led_worker(struct work_struct *work)
hid_output_report(report, buf);
/* synchronous output report */
- hid->hid_output_raw_report(hid, buf, len, HID_OUTPUT_REPORT);
+ hid_output_raw_report(hid, buf, len, HID_OUTPUT_REPORT);
kfree(buf);
}
diff --git a/drivers/hid/hid-lg.c b/drivers/hid/hid-lg.c
index 9fe9d4a..76ed7e5 100644
--- a/drivers/hid/hid-lg.c
+++ b/drivers/hid/hid-lg.c
@@ -692,7 +692,8 @@ static int lg_probe(struct hid_device *hdev, const struct hid_device_id *id)
if (hdev->product == USB_DEVICE_ID_LOGITECH_WII_WHEEL) {
unsigned char buf[] = { 0x00, 0xAF, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };
- ret = hdev->hid_output_raw_report(hdev, buf, sizeof(buf), HID_FEATURE_REPORT);
+ ret = hid_output_raw_report(hdev, buf, sizeof(buf),
+ HID_FEATURE_REPORT);
if (ret >= 0) {
/* insert a little delay of 10 jiffies ~ 40ms */
@@ -704,7 +705,8 @@ static int lg_probe(struct hid_device *hdev, const struct hid_device_id *id)
buf[1] = 0xB2;
get_random_bytes(&buf[2], 2);
- ret = hdev->hid_output_raw_report(hdev, buf, sizeof(buf), HID_FEATURE_REPORT);
+ ret = hid_output_raw_report(hdev, buf, sizeof(buf),
+ HID_FEATURE_REPORT);
}
}
diff --git a/drivers/hid/hid-logitech-dj.c b/drivers/hid/hid-logitech-dj.c
index 61d2bbf..9347625 100644
--- a/drivers/hid/hid-logitech-dj.c
+++ b/drivers/hid/hid-logitech-dj.c
@@ -567,7 +567,7 @@ static int logi_dj_output_hidraw_report(struct hid_device *hid, u8 * buf,
out_buf[1] = djdev->device_index;
memcpy(out_buf + 2, buf, count);
- ret = djrcv_dev->hdev->hid_output_raw_report(djrcv_dev->hdev, out_buf,
+ ret = hid_output_raw_report(djrcv_dev->hdev, out_buf,
DJREPORT_SHORT_LENGTH, report_type);
kfree(out_buf);
diff --git a/drivers/hid/hid-magicmouse.c b/drivers/hid/hid-magicmouse.c
index 3b43d1c..cb5db3a 100644
--- a/drivers/hid/hid-magicmouse.c
+++ b/drivers/hid/hid-magicmouse.c
@@ -538,7 +538,7 @@ static int magicmouse_probe(struct hid_device *hdev,
* but there seems to be no other way of switching the mode.
* Thus the super-ugly hacky success check below.
*/
- ret = hdev->hid_output_raw_report(hdev, feature, sizeof(feature),
+ ret = hid_output_raw_report(hdev, feature, sizeof(feature),
HID_FEATURE_REPORT);
if (ret != -EIO && ret != sizeof(feature)) {
hid_err(hdev, "unable to request touch data (%d)\n", ret);
diff --git a/drivers/hid/hid-sony.c b/drivers/hid/hid-sony.c
index 3930acb..8494b8c 100644
--- a/drivers/hid/hid-sony.c
+++ b/drivers/hid/hid-sony.c
@@ -720,7 +720,8 @@ static int sixaxis_set_operational_usb(struct hid_device *hdev)
static int sixaxis_set_operational_bt(struct hid_device *hdev)
{
unsigned char buf[] = { 0xf4, 0x42, 0x03, 0x00, 0x00 };
- return hdev->hid_output_raw_report(hdev, buf, sizeof(buf), HID_FEATURE_REPORT);
+ return hid_output_raw_report(hdev, buf, sizeof(buf),
+ HID_FEATURE_REPORT);
}
static void buzz_set_leds(struct hid_device *hdev, const __u8 *leds)
@@ -942,7 +943,7 @@ static void sixaxis_state_worker(struct work_struct *work)
buf[10] |= sc->led_state[2] << 3;
buf[10] |= sc->led_state[3] << 4;
- sc->hdev->hid_output_raw_report(sc->hdev, buf, sizeof(buf),
+ hid_output_raw_report(sc->hdev, buf, sizeof(buf),
HID_OUTPUT_REPORT);
}
diff --git a/drivers/hid/hid-thingm.c b/drivers/hid/hid-thingm.c
index 99342cf..7dd3197 100644
--- a/drivers/hid/hid-thingm.c
+++ b/drivers/hid/hid-thingm.c
@@ -48,8 +48,8 @@ static int blink1_send_command(struct blink1_data *data,
buf[0], buf[1], buf[2], buf[3], buf[4],
buf[5], buf[6], buf[7], buf[8]);
- ret = data->hdev->hid_output_raw_report(data->hdev, buf,
- BLINK1_CMD_SIZE, HID_FEATURE_REPORT);
+ ret = hid_output_raw_report(data->hdev, buf, BLINK1_CMD_SIZE,
+ HID_FEATURE_REPORT);
return ret < 0 ? ret : 0;
}
diff --git a/drivers/hid/hid-wacom.c b/drivers/hid/hid-wacom.c
index 60c75dc..c720db9 100644
--- a/drivers/hid/hid-wacom.c
+++ b/drivers/hid/hid-wacom.c
@@ -128,8 +128,7 @@ static void wacom_set_image(struct hid_device *hdev, const char *image,
rep_data[0] = WAC_CMD_ICON_START_STOP;
rep_data[1] = 0;
- ret = hdev->hid_output_raw_report(hdev, rep_data, 2,
- HID_FEATURE_REPORT);
+ ret = hid_output_raw_report(hdev, rep_data, 2, HID_FEATURE_REPORT);
if (ret < 0)
goto err;
@@ -143,15 +142,14 @@ static void wacom_set_image(struct hid_device *hdev, const char *image,
rep_data[j + 3] = p[(i << 6) + j];
rep_data[2] = i;
- ret = hdev->hid_output_raw_report(hdev, rep_data, 67,
+ ret = hid_output_raw_report(hdev, rep_data, 67,
HID_FEATURE_REPORT);
}
rep_data[0] = WAC_CMD_ICON_START_STOP;
rep_data[1] = 0;
- ret = hdev->hid_output_raw_report(hdev, rep_data, 2,
- HID_FEATURE_REPORT);
+ ret = hid_output_raw_report(hdev, rep_data, 2, HID_FEATURE_REPORT);
err:
return;
@@ -183,7 +181,7 @@ static void wacom_leds_set_brightness(struct led_classdev *led_dev,
buf[3] = value;
/* use fixed brightness for OLEDs */
buf[4] = 0x08;
- hdev->hid_output_raw_report(hdev, buf, 9, HID_FEATURE_REPORT);
+ hid_output_raw_report(hdev, buf, 9, HID_FEATURE_REPORT);
kfree(buf);
}
@@ -339,7 +337,7 @@ static void wacom_set_features(struct hid_device *hdev, u8 speed)
rep_data[0] = 0x03 ; rep_data[1] = 0x00;
limit = 3;
do {
- ret = hdev->hid_output_raw_report(hdev, rep_data, 2,
+ ret = hid_output_raw_report(hdev, rep_data, 2,
HID_FEATURE_REPORT);
} while (ret < 0 && limit-- > 0);
@@ -352,7 +350,7 @@ static void wacom_set_features(struct hid_device *hdev, u8 speed)
rep_data[1] = 0x00;
limit = 3;
do {
- ret = hdev->hid_output_raw_report(hdev,
+ ret = hid_output_raw_report(hdev,
rep_data, 2, HID_FEATURE_REPORT);
} while (ret < 0 && limit-- > 0);
@@ -378,7 +376,7 @@ static void wacom_set_features(struct hid_device *hdev, u8 speed)
rep_data[0] = 0x03;
rep_data[1] = wdata->features;
- ret = hdev->hid_output_raw_report(hdev, rep_data, 2,
+ ret = hid_output_raw_report(hdev, rep_data, 2,
HID_FEATURE_REPORT);
if (ret >= 0)
wdata->high_speed = speed;
diff --git a/drivers/hid/hid-wiimote-core.c b/drivers/hid/hid-wiimote-core.c
index abb20db..d7dc6c5b 100644
--- a/drivers/hid/hid-wiimote-core.c
+++ b/drivers/hid/hid-wiimote-core.c
@@ -35,7 +35,7 @@ static int wiimote_hid_send(struct hid_device *hdev, __u8 *buffer,
if (!buf)
return -ENOMEM;
- ret = hdev->hid_output_raw_report(hdev, buf, count, HID_OUTPUT_REPORT);
+ ret = hid_output_raw_report(hdev, buf, count, HID_OUTPUT_REPORT);
kfree(buf);
return ret;
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c
index 4b2dc95..f8708c9 100644
--- a/drivers/hid/hidraw.c
+++ b/drivers/hid/hidraw.c
@@ -153,7 +153,7 @@ static ssize_t hidraw_send_report(struct file *file, const char __user *buffer,
goto out_free;
}
- ret = dev->hid_output_raw_report(dev, buf, count, report_type);
+ ret = hid_output_raw_report(dev, buf, count, report_type);
out_free:
kfree(buf);
out:
diff --git a/include/linux/hid.h b/include/linux/hid.h
index c56681a..a837ede 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -1012,6 +1012,22 @@ static inline int hid_hw_output_report(struct hid_device *hdev, __u8 *buf,
}
/**
+ * hid_output_raw_report - send an output or a feature report to the device
+ *
+ * @hdev: hid device
+ * @buf: raw data to transfer
+ * @len: length of buf
+ * @report_type: HID_FEATURE_REPORT or HID_OUTPUT_REPORT
+ *
+ * @return: count of data transfered, negative if error
+ */
+static inline int hid_output_raw_report(struct hid_device *hdev, __u8 *buf,
+ size_t len, unsigned char report_type)
+{
+ return hdev->hid_output_raw_report(hdev, buf, len, report_type);
+}
+
+/**
* hid_hw_idle - send idle request to device
*
* @hdev: hid device
--
1.8.3.1
^ permalink raw reply related
* [PATCH] Add Apple wireless keyboard 2011 JIS model support
From: Huei-Horng Yo @ 2014-02-03 5:19 UTC (permalink / raw)
To: linux-input
Hello,
I bought a Apple wireless keyboard 2011 JIS model,
the fn key isn't work as expected in Linux 3.12.9 (current version I am
using),
I then read the kernel source code, found that it was not listed in HID
IDs list,
so that I made a patch as below to add the model support.
P.S: Also reported in Bugzilla:
https://bugzilla.kernel.org/show_bug.cgi?id=69681
Thanks,
Huei-Horng Yo
apple-alu-wireless-kbd-jis.patch
Signed-off-by: Huei-Horng Yo <hiroshi@ghostsinthelab.org>
diff -uprN linux-3.12.vanilla/drivers/hid/hid-apple.c
linux-3.12/drivers/hid/hid-apple.c
--- linux-3.12.vanilla/drivers/hid/hid-apple.c 2013-11-04
07:41:51.000000000 +0800
+++ linux-3.12/drivers/hid/hid-apple.c 2014-02-01 01:15:37.532768035 +0800
@@ -447,6 +447,9 @@ static const struct hid_device_id apple_
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_ANSI),
.driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN },
+ { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
+ USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_JIS),
+ .driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN },
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_ALU_WIRELESS_JIS),
.driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN },
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_WELLSPRING_ANSI),
diff -uprN linux-3.12.vanilla/drivers/hid/hid-core.c
linux-3.12/drivers/hid/hid-core.c
--- linux-3.12.vanilla/drivers/hid/hid-core.c 2013-11-04
07:41:51.000000000 +0800
+++ linux-3.12/drivers/hid/hid-core.c 2014-02-01 01:15:37.532768035 +0800
@@ -1680,6 +1680,7 @@ static const struct hid_device_id hid_ha
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_JIS) },
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_ANSI) },
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_ISO) },
+ { HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_JIS) },
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_FOUNTAIN_TP_ONLY) },
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE,
USB_DEVICE_ID_APPLE_GEYSER1_TP_ONLY) },
{ HID_USB_DEVICE(USB_VENDOR_ID_AUREAL,
USB_DEVICE_ID_AUREAL_W01RN) },
diff -uprN linux-3.12.vanilla/drivers/hid/hid-ids.h
linux-3.12/drivers/hid/hid-ids.h
--- linux-3.12.vanilla/drivers/hid/hid-ids.h 2013-11-04
07:41:51.000000000 +0800
+++ linux-3.12/drivers/hid/hid-ids.h 2014-02-01 01:15:37.532768035 +0800
@@ -135,6 +135,7 @@
#define USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_JIS 0x023b
#define USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_ANSI 0x0255
#define USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_ISO 0x0256
+#define USB_DEVICE_ID_APPLE_ALU_WIRELESS_2011_JIS 0x0257
#define USB_DEVICE_ID_APPLE_WELLSPRING8_ANSI 0x0290
#define USB_DEVICE_ID_APPLE_WELLSPRING8_ISO 0x0291
#define USB_DEVICE_ID_APPLE_WELLSPRING8_JIS 0x0292
^ permalink raw reply
* [PATCH] HID: hid-sensor-hub: quirk for STM Sensor hub
From: Archana Patni @ 2014-02-03 7:14 UTC (permalink / raw)
To: jkosina; +Cc: jic23, linux-input, srinivas.pandruvada, Archana Patni
Added STM sensor hub vendor id in HID_SENSOR_HUB_ENUM_QUIRK to
fix report descriptors. These devices uses old FW which uses
logical 0 as minimum. In these, HID reports are not using proper
collection classes. So we need to fix report descriptors,for
such devices. This will not have any impact, if the FW uses
logical 1 as minimum.
We look for usage id for "power and report state", and modify
logical minimum value to 1.
This is a follow-up patch to commit id 875e36f8.
Signed-off-by: Archana Patni <archana.patni@linux.intel.com>
Reviewed-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
---
drivers/hid/hid-ids.h | 3 +++
drivers/hid/hid-sensor-hub.c | 3 +++
2 files changed, 6 insertions(+)
diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
index 5a5248f..1fc5bee 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -451,6 +451,9 @@
#define USB_VENDOR_ID_INTEL_1 0x8087
#define USB_DEVICE_ID_INTEL_HID_SENSOR 0x09fa
+#define USB_VENDOR_ID_STM_0 0x0483
+#define USB_DEVICE_ID_STM_HID_SENSOR 0x91d1
+
#define USB_VENDOR_ID_ION 0x15e4
#define USB_DEVICE_ID_ICADE 0x0132
diff --git a/drivers/hid/hid-sensor-hub.c b/drivers/hid/hid-sensor-hub.c
index 46f4480..9c22e14 100644
--- a/drivers/hid/hid-sensor-hub.c
+++ b/drivers/hid/hid-sensor-hub.c
@@ -665,6 +665,9 @@ static const struct hid_device_id sensor_hub_devices[] = {
{ HID_DEVICE(HID_BUS_ANY, HID_GROUP_SENSOR_HUB, USB_VENDOR_ID_INTEL_1,
USB_DEVICE_ID_INTEL_HID_SENSOR),
.driver_data = HID_SENSOR_HUB_ENUM_QUIRK},
+ { HID_DEVICE(HID_BUS_ANY, HID_GROUP_SENSOR_HUB, USB_VENDOR_ID_STM_0,
+ USB_DEVICE_ID_STM_HID_SENSOR),
+ .driver_data = HID_SENSOR_HUB_ENUM_QUIRK},
{ HID_DEVICE(HID_BUS_ANY, HID_GROUP_SENSOR_HUB, HID_ANY_ID,
HID_ANY_ID) },
{ }
--
1.7.9.5
^ permalink raw reply related
* Re: [PATCH 4/7] Input: xpad: Set the correct LED number
From: Greg Kroah-Hartman @ 2014-02-03 8:22 UTC (permalink / raw)
To: dmitry.torokhov; +Cc: linux-input, Pierre-Loup A. Griffais
In-Reply-To: <1391173414-6199-5-git-send-email-gregkh@linuxfoundation.org>
On Fri, Jan 31, 2014 at 02:03:31PM +0100, Greg Kroah-Hartman wrote:
> From: "Pierre-Loup A. Griffais" <pgriffais@valvesoftware.com>
>
> The LED number should not just be incremented every time, that doesn't
> work, set the number based on the number it actually is.
>
> Note, the joydev subsystem doesn't allow us to easily find out the minor
> number, so we have to walk all devices in order to find a joystick
> device by looking at the name of the device. Odds are, this isn't the
> best way to do it, but I don't know of any other way at the moment.
>
> Signed-off-by: "Pierre-Loup A. Griffais" <pgriffais@valvesoftware.com>
> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> ---
> drivers/input/joystick/xpad.c | 26 +++++++++++++++++++++-----
> 1 file changed, 21 insertions(+), 5 deletions(-)
I'll preempt David's NAK of this patch before he gets a chance to catch
up on his email from being at FOSDEM :)
I spent some time talking with David about this, and I think I know a
better way to handle this instead of the "walk the joystick devices"
mess that should work for systems that don't even use joydev (which
"modern" systems shouldn't be using anyway.)
So I'll do a respin of this patch series in a week or so when I catch up
with my other stuff and send it out again...
But, if someone wants to review the other 6 in this series, that would
be great.
thanks,
greg k-h
^ permalink raw reply
* Re: [PATCH] HID: fix buffer allocations
From: Jiri Kosina @ 2014-02-03 10:03 UTC (permalink / raw)
To: Benjamin Tissoires; +Cc: Benjamin Tissoires, linux-input, linux-kernel
In-Reply-To: <1391314990-29046-1-git-send-email-benjamin.tissoires@redhat.com>
On Sat, 1 Feb 2014, Benjamin Tissoires wrote:
> When using hid_output_report(), the buffer should be allocated by hid_alloc_report_buf(),
> not a custom malloc.
>
> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Good catch, applied, thanks.
--
Jiri Kosina
SUSE Labs
^ permalink raw reply
* Re: [PATCH] Bluetooth: hidp: make sure input buffers are big enough
From: Jiri Kosina @ 2014-02-03 10:08 UTC (permalink / raw)
To: David Herrmann
Cc: Marcel Holtmann, open list:HID CORE LAYER,
linux-bluetooth@vger.kernel.org development, Gustavo F. Padovan
In-Reply-To: <CANq1E4TW+GU=oaW0tXb=Tun9HMtr26u-PC3H6BsLot560ANgog@mail.gmail.com>
On Wed, 29 Jan 2014, David Herrmann wrote:
> >> Due to various reasons I will not have access to any testing HW for the
> >> upcoming 2-3 days, so if you can cook something up in that timeframe, it'd
> >> be appreciated.
> >>
> >> Otherwise I'll be working on it by the end of this week.
> >
> > David,
> >
> > just got back to this, finally ... did you have time to work on this at
> > all, or should I just start from scratch?
>
> Sorry, no. Fosdem is this weekend and I needed to get my code ready
> for that. But I'll finally have time again next week.
Okay, thanks. I then guess we should proceed with this bandaid (double
allocation) for 3.14
--
Jiri Kosina
SUSE Labs
^ permalink raw reply
* Re: [PATCH 0/4] input: Add support for special keys on ms office kb
From: Jiri Kosina @ 2014-02-03 10:12 UTC (permalink / raw)
To: Hans de Goede; +Cc: linux-input
In-Reply-To: <1391014664-2642-1-git-send-email-hdegoede@redhat.com>
On Wed, 29 Jan 2014, Hans de Goede wrote:
> A member of my local hackerspace has donated a Microsoft Office keyboard to
> me. This keyboard has lots of special keys, some of which don't work
> and a scrollwheel which does not work. This patch-set adds support for the
> scrollwheel and the non working special-keys.
Applied, thanks Hans.
--
Jiri Kosina
SUSE Labs
^ permalink raw reply
* Re: [PATCH 2/3 RESEND] mfd: tc3589x: Reform device tree probing
From: Linus Walleij @ 2014-02-03 10:32 UTC (permalink / raw)
To: Lee Jones
Cc: devicetree@vger.kernel.org, Dmitry Torokhov, Linux Input,
Samuel Ortiz, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, Mark Rutland
In-Reply-To: <20140123151123.GE8586@lee--X1>
On Thu, Jan 23, 2014 at 4:11 PM, Lee Jones <lee.jones@linaro.org> wrote:
>> > Patch looks good to me. Is there any reason why we should rush this in
>> > for v3.14, or is it okay to go to -next?
>>
>> No rush, but it's been on review like forever so unless there is
>> some noise from the DT people at -rc1 I'd be very happy if you
>> could apply patches 1 & 2 by then.
>
> I'm just waiting for their Ack. If I don't have it soon I'll review it
> myself and any changes will have to come in via subsequent patch
> submissions.
>
> I think it's sensible to head for v3.15 for this set.
So now that v3.14-rc1 is out can we queue this stuff?
Yours,
Linus Walleij
^ permalink raw reply
* Re: [PATCH 2/3 RESEND] mfd: tc3589x: Reform device tree probing
From: Lee Jones @ 2014-02-03 11:01 UTC (permalink / raw)
To: Linus Walleij
Cc: devicetree, Dmitry Torokhov, linux-input, Samuel Ortiz,
linux-kernel, linux-arm-kernel, Mark Rutland
In-Reply-To: <1390481008-23900-1-git-send-email-linus.walleij@linaro.org>
> This changes the following mechanisms in the TC3589x device tree
> probing path:
>
> - Use the .of_match_table in struct device_driver to match the
> device in the device tree.
> - Add matches for the proper compatible strings "toshiba,..."
> and all sub-variants, just as is done for the .id matches.
> - Move over all the allocation of platform data etc to the
> tc3589x_of_probe() function and follow the pattern of passing
> a platform data pointer back, or an error pointer on error,
> as found in the STMPE driver.
> - Match the new (proper) compatible strings for the GPIO and
> keypad MFD cells.
> - Use of_device_is_compatible() rather than just !strcmp()
> to discover which cells to instantiate.
>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> drivers/mfd/tc3589x.c | 84 ++++++++++++++++++++++++++++++++++++---------------
> 1 file changed, 59 insertions(+), 25 deletions(-)
Looks good, applied.
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox