Commit 54286fd0da36a51f4cefe669b70a284a799f3e45

Authored by Mattia Dongili
Committed by Matthew Garrett
1 parent 56e6e716b5

sony-laptop: documentation updates

Signed-off-by: Mattia Dongili <malattia@linux.it>
Signed-off-by: Matthew Garrett <mjg@redhat.com>

Showing 1 changed file with 30 additions and 7 deletions Side-by-side Diff

Documentation/laptops/sony-laptop.txt
... ... @@ -14,7 +14,8 @@
14 14 reported both through the ACPI subsystem as acpi events and through the INPUT
15 15 subsystem. See the logs of acpid or /proc/acpi/event and
16 16 /proc/bus/input/devices to find out what those events are and which input
17   -devices are created by the driver.
  17 +devices are created by the driver. Additionally, loading the driver with the
  18 +debug option will report all events in the kernel log.
18 19  
19 20 Backlight control:
20 21 ------------------
... ... @@ -64,6 +65,16 @@
64 65 # echo "1" > /sys/devices/platform/sony-laptop/audiopower
65 66 powers on the sound card.
66 67  
  68 +
  69 +RFkill control:
  70 +---------------
  71 +More recent Vaio models expose a consistent set of ACPI methods to
  72 +control radio frequency emitting devices. If you are a lucky owner of
  73 +such a laptop you will find the necessary rfkill devices under
  74 +/sys/class/rfkill. Check those starting with sony-* in
  75 + # grep . /sys/class/rfkill/*/{state,name}
  76 +
  77 +
67 78 Development:
68 79 ------------
69 80  
70 81  
... ... @@ -75,9 +86,22 @@
75 86 REPEAT: DON'T DO THIS IF YOU DON'T LIKE RISKY BUSINESS.
76 87  
77 88 In your kernel logs you will find the list of all ACPI methods
78   -the SNC device has on your laptop. You can see the GCDP/GCDP methods
79   -used to pwer on/off the CD drive, but there are others.
  89 +the SNC device has on your laptop.
80 90  
  91 +* For new models you will see a long list of meaningless method names,
  92 +reading the DSDT table source should reveal that:
  93 +(1) the SNC device uses an internal capability lookup table
  94 +(2) SN00 is used to find values in the lookup table
  95 +(3) SN06 and SN07 are used to call into the real methods based on
  96 + offsets you can obtain iterating the table using SN00
  97 +(4) SN02 used to enable events.
  98 +Some values in the capability lookup table are more or less known, see
  99 +the code for all sony_call_snc_handle calls, others are more obscure.
  100 +
  101 +* For old models you can see the GCDP/GCDP methods used to pwer on/off
  102 +the CD drive, but there are others and they are usually different from
  103 +model to model.
  104 +
81 105 I HAVE NO IDEA WHAT THOSE METHODS DO.
82 106  
83 107 The sony-laptop driver creates, for some of those methods (the most
84 108  
... ... @@ -108,10 +132,9 @@
108 132 laptop, including permanent damage.
109 133  
110 134 * The sony-laptop and sonypi drivers do not interact at all. In the
111   - future, sonypi could use sony-laptop to do (part of) its business.
  135 + future, sonypi will be removed and replaced by sony-laptop.
112 136  
113 137 * spicctrl, which is the userspace tool used to communicate with the
114   - sonypi driver (through /dev/sonypi) does not try to use the
115   - sony-laptop driver. In the future, spicctrl could try sonypi first,
116   - and if it isn't present, try sony-laptop instead.
  138 + sonypi driver (through /dev/sonypi) is deprecated as well since all
  139 + its features are now available under the sysfs tree via sony-laptop.