<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/platform/chrome, branch v4.4.80</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>mfd: cros_ec: Add cros_ec_cmd_xfer_status() helper</title>
<updated>2016-09-07T06:32:43+00:00</updated>
<author>
<name>Tomeu Vizoso</name>
<email>tomeu.vizoso@collabora.com</email>
</author>
<published>2016-07-15T23:28:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d91c348e4c3a011849e309cb76a6fdc714935ea4'/>
<id>d91c348e4c3a011849e309cb76a6fdc714935ea4</id>
<content type='text'>
commit 9798ac6d32c1a32d6d92d853ff507d2d39c4300c upstream.

So that callers of cros_ec_cmd_xfer() don't have to repeat boilerplate
code when checking for errors from the EC side.

Signed-off-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Reviewed-by: Benson Leung &lt;bleung@chromium.org&gt;
Signed-off-by: Brian Norris &lt;briannorris@chromium.org&gt;
Acked-by: Lee Jones &lt;lee.jones@linaro.org&gt;
Tested-by: Enric Balletbo i Serra &lt;enric.balletbo@collabora.com&gt;
Signed-off-by: Thierry Reding &lt;thierry.reding@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 9798ac6d32c1a32d6d92d853ff507d2d39c4300c upstream.

So that callers of cros_ec_cmd_xfer() don't have to repeat boilerplate
code when checking for errors from the EC side.

Signed-off-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Reviewed-by: Benson Leung &lt;bleung@chromium.org&gt;
Signed-off-by: Brian Norris &lt;briannorris@chromium.org&gt;
Acked-by: Lee Jones &lt;lee.jones@linaro.org&gt;
Tested-by: Enric Balletbo i Serra &lt;enric.balletbo@collabora.com&gt;
Signed-off-by: Thierry Reding &lt;thierry.reding@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: cros_ec_dev - double fetch bug in ioctl</title>
<updated>2016-08-10T09:49:28+00:00</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@oracle.com</email>
</author>
<published>2016-06-21T13:58:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=69ca969a2626dc4b3bb83b953c053a01e3b9f7e6'/>
<id>69ca969a2626dc4b3bb83b953c053a01e3b9f7e6</id>
<content type='text'>
commit 096cdc6f52225835ff503f987a0d68ef770bb78e upstream.

We verify "u_cmd.outsize" and "u_cmd.insize" but we need to make sure
that those values have not changed between the two copy_from_user()
calls.  Otherwise it could lead to a buffer overflow.

Additionally, cros_ec_cmd_xfer() can set s_cmd-&gt;insize to a lower value.
We should use the new smaller value so we don't copy too much data to
the user.

Reported-by: Pengfei Wang &lt;wpengfeinudt@gmail.com&gt;
Fixes: a841178445bb ('mfd: cros_ec: Use a zero-length array for command data')
Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Reviewed-by: Kees Cook &lt;keescook@chromium.org&gt;
Tested-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 096cdc6f52225835ff503f987a0d68ef770bb78e upstream.

We verify "u_cmd.outsize" and "u_cmd.insize" but we need to make sure
that those values have not changed between the two copy_from_user()
calls.  Otherwise it could lead to a buffer overflow.

Additionally, cros_ec_cmd_xfer() can set s_cmd-&gt;insize to a lower value.
We should use the new smaller value so we don't copy too much data to
the user.

Reported-by: Pengfei Wang &lt;wpengfeinudt@gmail.com&gt;
Fixes: a841178445bb ('mfd: cros_ec: Use a zero-length array for command data')
Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Reviewed-by: Kees Cook &lt;keescook@chromium.org&gt;
Tested-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: Fix i2c-designware adapter name</title>
<updated>2015-11-10T03:43:33+00:00</updated>
<author>
<name>Jarkko Nikula</name>
<email>jarkko.nikula@linux.intel.com</email>
</author>
<published>2015-11-03T11:09:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=ebaf31c46cce0dc8a6ed690b5456b295aa7586a6'/>
<id>ebaf31c46cce0dc8a6ed690b5456b295aa7586a6</id>
<content type='text'>
Commit d80d134182ba ("i2c: designware: Move common probe code into
i2c_dw_probe()") caused the I2C adapter lookup code here to fail for PCI
enumerated i2c-designware because commit changed the adapter name but
didn't update it here.

Fix the I2C adapter lookup by using the "Synopsys DesignWare I2C adapter"
name.

Reported-by: Jeremiah Mahler &lt;jmmahler@gmail.com&gt;
Fixes: d80d134182ba ("i2c: designware: Move common probe code into i2c_dw_probe()")
Signed-off-by: Jarkko Nikula &lt;jarkko.nikula@linux.intel.com&gt;
Tested-by: Jeremiah Mahler &lt;jmmahler@gmail.com&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit d80d134182ba ("i2c: designware: Move common probe code into
i2c_dw_probe()") caused the I2C adapter lookup code here to fail for PCI
enumerated i2c-designware because commit changed the adapter name but
didn't update it here.

Fix the I2C adapter lookup by using the "Synopsys DesignWare I2C adapter"
name.

Reported-by: Jeremiah Mahler &lt;jmmahler@gmail.com&gt;
Fixes: d80d134182ba ("i2c: designware: Move common probe code into i2c_dw_probe()")
Signed-off-by: Jarkko Nikula &lt;jarkko.nikula@linux.intel.com&gt;
Tested-by: Jeremiah Mahler &lt;jmmahler@gmail.com&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: Support reading/writing the vboot context</title>
<updated>2015-10-07T22:05:53+00:00</updated>
<author>
<name>Emilio López</name>
<email>emilio.lopez@collabora.co.uk</email>
</author>
<published>2015-09-21T13:38:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=18800fc7a04e7df8a345e7ef4fc3064368276f83'/>
<id>18800fc7a04e7df8a345e7ef4fc3064368276f83</id>
<content type='text'>
Some EC implementations include a small nvram space used to store
verified boot context data. This patch offers a way to expose this
data to userspace.

Reviewed-by: Javier Martinez Canillas &lt;javier@osg.samsung.com&gt;
Signed-off-by: Emilio López &lt;emilio.lopez@collabora.co.uk&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some EC implementations include a small nvram space used to store
verified boot context data. This patch offers a way to expose this
data to userspace.

Reviewed-by: Javier Martinez Canillas &lt;javier@osg.samsung.com&gt;
Signed-off-by: Emilio López &lt;emilio.lopez@collabora.co.uk&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: cros_ec: Fix possible leak in led_rgb_store()</title>
<updated>2015-10-07T21:34:26+00:00</updated>
<author>
<name>Christian Engelmayer</name>
<email>cengelma@gmx.at</email>
</author>
<published>2015-07-19T19:43:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f14ae099bdad32414ad968909973bfade9b37967'/>
<id>f14ae099bdad32414ad968909973bfade9b37967</id>
<content type='text'>
Function led_rgb_store() contains some direct returns in error cases that
leak the already allocated cros_ec_command message structure. Make sure
that 'msg' is freed in all exit paths. Detected by Coverity CID 1309666.

Signed-off-by: Christian Engelmayer &lt;cengelma@gmx.at&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Function led_rgb_store() contains some direct returns in error cases that
leak the already allocated cros_ec_command message structure. Make sure
that 'msg' is freed in all exit paths. Detected by Coverity CID 1309666.

Signed-off-by: Christian Engelmayer &lt;cengelma@gmx.at&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: cros_ec: Fix leak in sequence_store()</title>
<updated>2015-10-07T21:34:26+00:00</updated>
<author>
<name>Christian Engelmayer</name>
<email>cengelma@gmx.at</email>
</author>
<published>2015-07-18T17:30:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=88dfb8b43d557ee9b1c1ffd2c8d275dd479a66d4'/>
<id>88dfb8b43d557ee9b1c1ffd2c8d275dd479a66d4</id>
<content type='text'>
The allocated cros_ec_command message structure is not freed in function
sequence_store(). Make sure that 'msg' is freed in all exit paths.
Detected by Coverity CID 1309667.

Signed-off-by: Christian Engelmayer &lt;cengelma@gmx.at&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The allocated cros_ec_command message structure is not freed in function
sequence_store(). Make sure that 'msg' is freed in all exit paths.
Detected by Coverity CID 1309667.

Signed-off-by: Christian Engelmayer &lt;cengelma@gmx.at&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: Enable Chrome platforms on 64-bit ARM</title>
<updated>2015-10-07T21:34:26+00:00</updated>
<author>
<name>Thierry Reding</name>
<email>treding@nvidia.com</email>
</author>
<published>2015-07-01T10:46:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=23ecee32b91cf732226bd7a3ee9fa7a9127645ab'/>
<id>23ecee32b91cf732226bd7a3ee9fa7a9127645ab</id>
<content type='text'>
With Chrome running on 64-bit ARM devices, add ARM64 to the list of
supported architectures.

Signed-off-by: Thierry Reding &lt;treding@nvidia.com&gt;
[olof; Fixed up due to addition of COMPILE_TEST]
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With Chrome running on 64-bit ARM devices, add ARM64 to the list of
supported architectures.

Signed-off-by: Thierry Reding &lt;treding@nvidia.com&gt;
[olof; Fixed up due to addition of COMPILE_TEST]
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: cros_ec_dev - Add a platform device ID table</title>
<updated>2015-10-07T21:34:26+00:00</updated>
<author>
<name>Javier Martinez Canillas</name>
<email>javier.martinez@collabora.co.uk</email>
</author>
<published>2015-06-22T06:27:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=afbf8ec7c4f90ddd3ee8655c591983fb9d399f43'/>
<id>afbf8ec7c4f90ddd3ee8655c591983fb9d399f43</id>
<content type='text'>
If the cros_ec_dev driver is built as a module, modalias information is
not filled so the module is not autoloaded. Add a platform device table
and use the MODULE_DEVICE_TABLE() macro to export that information in
the module so user-space can match the modalias uevent and autoload it.

Signed-off-by: Javier Martinez Canillas &lt;javier.martinez@collabora.co.uk&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If the cros_ec_dev driver is built as a module, modalias information is
not filled so the module is not autoloaded. Add a platform device table
and use the MODULE_DEVICE_TABLE() macro to export that information in
the module so user-space can match the modalias uevent and autoload it.

Signed-off-by: Javier Martinez Canillas &lt;javier.martinez@collabora.co.uk&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: cros_ec_lpc - Add support for Google Pixel 2</title>
<updated>2015-10-07T21:34:26+00:00</updated>
<author>
<name>Javier Martinez Canillas</name>
<email>javier.martinez@collabora.co.uk</email>
</author>
<published>2015-06-22T06:27:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=85bba84ead5cec41add1cbdb2978e572add10deb'/>
<id>85bba84ead5cec41add1cbdb2978e572add10deb</id>
<content type='text'>
Since the verion of ACPI in Google BIOS does not enumerate the devices
in the LPC bus, the cros_ec_lpc driver resorts to DMI data to check if
a system is supported by the driver and autoload if built as a module.

Add information about the Google Pixel 2 to the DMI device table.

Signed-off-by: Javier Martinez Canillas &lt;javier.martinez@collabora.co.uk&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since the verion of ACPI in Google BIOS does not enumerate the devices
in the LPC bus, the cros_ec_lpc driver resorts to DMI data to check if
a system is supported by the driver and autoload if built as a module.

Add information about the Google Pixel 2 to the DMI device table.

Signed-off-by: Javier Martinez Canillas &lt;javier.martinez@collabora.co.uk&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>platform/chrome: cros_ec_lpc - Use existing function to check EC result</title>
<updated>2015-10-07T21:34:26+00:00</updated>
<author>
<name>Javier Martinez Canillas</name>
<email>javier.martinez@collabora.co.uk</email>
</author>
<published>2015-06-22T06:27:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=fbf40727c781a3b8562e76a86cd08a111414d1c7'/>
<id>fbf40727c781a3b8562e76a86cd08a111414d1c7</id>
<content type='text'>
Commit 6db07b633658 ("mfd: cros_ec: Check result code from EC messages")
added a common cros_ec_check_result() function that can be used to check
the ec_msg-&gt;result for errors and warns about them.

Use the existing function instead of duplicating same check in the driver.

Signed-off-by: Javier Martinez Canillas &lt;javier.martinez@collabora.co.uk&gt;
Reviewed-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Tested-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 6db07b633658 ("mfd: cros_ec: Check result code from EC messages")
added a common cros_ec_check_result() function that can be used to check
the ec_msg-&gt;result for errors and warns about them.

Use the existing function instead of duplicating same check in the driver.

Signed-off-by: Javier Martinez Canillas &lt;javier.martinez@collabora.co.uk&gt;
Reviewed-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Tested-by: Gwendal Grignou &lt;gwendal@chromium.org&gt;
Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</pre>
</div>
</content>
</entry>
</feed>
