<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/acpi/ec_sys.c, branch v6.19.11</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.19.11'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2021-12-01T19:19:30+00:00</updated>
<entry>
<title>ACPI: EC: Mark the ec_sys write_support param as module_param_hw()</title>
<updated>2021-12-01T19:19:30+00:00</updated>
<author>
<name>Hans de Goede</name>
<email>hdegoede@redhat.com</email>
</author>
<published>2021-11-25T10:36:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=b66f86849414807745b5c2129e2de5f27a788c9f'/>
<id>urn:sha1:b66f86849414807745b5c2129e2de5f27a788c9f</id>
<content type='text'>
Using write_support=1 with the ec_sys module changes the mode of the
"io" debugfs file to 0600. This will cause any attempts to access it under
a kernel in lockdown mode to return -EPERM, which makes the entire ec_sys
module unusable.

Use the special module_param_hw() macro for module parameters which
may not be used while in lockdown mode, to avoid this.

Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 482</title>
<updated>2019-06-19T15:09:52+00:00</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2019-06-04T08:11:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7a338472f225f18694cc4d9ad1f6f9428f4a88d0'/>
<id>urn:sha1:7a338472f225f18694cc4d9ad1f6f9428f4a88d0</id>
<content type='text'>
Based on 1 normalized pattern(s):

  this work is licensed under the terms of the gnu gpl version 2

extracted by the scancode license scanner the SPDX license identifier

  GPL-2.0-only

has been chosen to replace the boilerplate/reference in 48 file(s).

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Allison Randal &lt;allison@lohutok.net&gt;
Reviewed-by: Enrico Weigelt &lt;info@metux.net&gt;
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190604081204.624030236@linutronix.de
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>ACPI: no need to check return value of debugfs_create functions</title>
<updated>2019-01-22T18:45:52+00:00</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2019-01-22T15:21:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9ec6dbfbdc0ade855e6bc1da66e263e0d926697c'/>
<id>urn:sha1:9ec6dbfbdc0ade855e6bc1da66e263e0d926697c</id>
<content type='text'>
When calling debugfs functions, there is no need to ever check the
return value.  The function can work or not, but the code logic should
never do something different based on this.

Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI: EC: Fix debugfs_create_*() usage</title>
<updated>2018-01-04T12:54:51+00:00</updated>
<author>
<name>Geert Uytterhoeven</name>
<email>geert+renesas@glider.be</email>
</author>
<published>2018-01-02T15:26:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3522f867c13b63cf62acdf1b8ca5664c549a716a'/>
<id>urn:sha1:3522f867c13b63cf62acdf1b8ca5664c549a716a</id>
<content type='text'>
acpi_ec.gpe is "unsigned long", hence treating it as "u32" would expose
the wrong half on big-endian 64-bit systems.  Fix this by changing its
type to "u32" and removing the cast, as all other code already uses u32
or sometimes even only u8.

Fixes: 1195a098168fcacf (ACPI: Provide /sys/kernel/debug/ec/...)
Signed-off-by: Geert Uytterhoeven &lt;geert+renesas@glider.be&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / EC: Deny write access unless requested by module param</title>
<updated>2016-03-09T22:26:15+00:00</updated>
<author>
<name>Oleg Drokin</name>
<email>green@linuxhacker.ru</email>
</author>
<published>2016-02-06T07:08:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1b6e75ee295990d866ded77c29ffc6f88b831e26'/>
<id>urn:sha1:1b6e75ee295990d866ded77c29ffc6f88b831e26</id>
<content type='text'>
In debugfs it's not enough to just set file mode to read-only to
deny write access to a file, instead just don't provide
the write method unless write access is really requested.

Signed-off-by: Oleg Drokin &lt;green@linuxhacker.ru&gt;
Acked-by: Thomas Renninger &lt;trenn@suse.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / EC: Fix broken 64bit big-endian users of 'global_lock'</title>
<updated>2015-10-04T10:36:07+00:00</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2015-09-26T22:04:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6e58f752a6502b43e039fd7df2c7c5cde8dde437'/>
<id>urn:sha1:6e58f752a6502b43e039fd7df2c7c5cde8dde437</id>
<content type='text'>
global_lock is defined as an unsigned long and accessing only its lower
32 bits from sysfs is incorrect, as we need to consider other 32 bits
for big endian 64-bit systems. There are no such platforms yet, but the
code needs to be robust for such a case.

Fix that by changing type of 'global_lock' to u32.

Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Acked-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>ACPI / EC: Mark the function acpi_ec_add_debugfs() as static in ec_sys.c</title>
<updated>2014-01-05T23:13:22+00:00</updated>
<author>
<name>Rashika</name>
<email>rashika.kheria@gmail.com</email>
</author>
<published>2013-12-17T09:16:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=49894d8d5ac19224520f6bec213bbeb120f7eb70'/>
<id>urn:sha1:49894d8d5ac19224520f6bec213bbeb120f7eb70</id>
<content type='text'>
Mark the function acpi_ec_add_debugfs() as static in
ec_sys.c because it is not used outside this file.

This eliminates the following warning in ec_sys.c:
drivers/acpi/ec_sys.c:108:5: warning: no previous prototype for ‘acpi_ec_add_debugfs’ [-Wmissing-prototypes]

Signed-off-by: Rashika Kheria &lt;rashika.kheria@gmail.com&gt;
Reviewed-by: Josh Triplett &lt;josh@joshtriplett.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>ACPI / EC: access user space with get_user()/put_user()</title>
<updated>2013-06-19T21:29:20+00:00</updated>
<author>
<name>Vasiliy Kulikov</name>
<email>segooon@gmail.com</email>
</author>
<published>2013-05-22T12:59:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ecde3003e5205a283b46b931c729a2aecab64ba1'/>
<id>urn:sha1:ecde3003e5205a283b46b931c729a2aecab64ba1</id>
<content type='text'>
User space pointer may not be dereferenced. Use get_user()/put_user()
instead and check their return codes.

Signed-off-by: Vasiliy Kulikov &lt;segooon@gmail.com&gt;
Signed-off-by: Thomas Renninger &lt;trenn@suse.de&gt;
Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>simple_open: automatically convert to simple_open()</title>
<updated>2012-04-05T22:25:50+00:00</updated>
<author>
<name>Stephen Boyd</name>
<email>sboyd@codeaurora.org</email>
</author>
<published>2012-04-05T21:25:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=234e340582901211f40d8c732afc49f0630ecf05'/>
<id>urn:sha1:234e340582901211f40d8c732afc49f0630ecf05</id>
<content type='text'>
Many users of debugfs copy the implementation of default_open() when
they want to support a custom read/write function op.  This leads to a
proliferation of the default_open() implementation across the entire
tree.

Now that the common implementation has been consolidated into libfs we
can replace all the users of this function with simple_open().

This replacement was done with the following semantic patch:

&lt;smpl&gt;
@ open @
identifier open_f != simple_open;
identifier i, f;
@@
-int open_f(struct inode *i, struct file *f)
-{
(
-if (i-&gt;i_private)
-f-&gt;private_data = i-&gt;i_private;
|
-f-&gt;private_data = i-&gt;i_private;
)
-return 0;
-}

@ has_open depends on open @
identifier fops;
identifier open.open_f;
@@
struct file_operations fops = {
...
-.open = open_f,
+.open = simple_open,
...
};
&lt;/smpl&gt;

[akpm@linux-foundation.org: checkpatch fixes]
Signed-off-by: Stephen Boyd &lt;sboyd@codeaurora.org&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Cc: Julia Lawall &lt;Julia.Lawall@lip6.fr&gt;
Acked-by: Ingo Molnar &lt;mingo@elte.hu&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>switch debugfs to umode_t</title>
<updated>2012-01-04T03:54:56+00:00</updated>
<author>
<name>Al Viro</name>
<email>viro@zeniv.linux.org.uk</email>
</author>
<published>2011-07-24T08:33:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f4ae40a6a50a98ac23d4b285f739455e926a473e'/>
<id>urn:sha1:f4ae40a6a50a98ac23d4b285f739455e926a473e</id>
<content type='text'>
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
</feed>
