<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/platform/chrome, branch v4.4.239</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v4.4.239</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v4.4.239'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2019-06-22T06:18:20+00:00</updated>
<entry>
<title>platform/chrome: cros_ec_proto: check for NULL transfer function</title>
<updated>2019-06-22T06:18:20+00:00</updated>
<author>
<name>Enrico Granata</name>
<email>egranata@chromium.org</email>
</author>
<published>2019-04-03T22:40:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=845676341c2d6079f682d13c852f448a3fc4c6f3'/>
<id>urn:sha1:845676341c2d6079f682d13c852f448a3fc4c6f3</id>
<content type='text'>
[ Upstream commit 94d4e7af14a1170e34cf082d92e4c02de9e9fb88 ]

As new transfer mechanisms are added to the EC codebase, they may
not support v2 of the EC protocol.

If the v3 initial handshake transfer fails, the kernel will try
and call cmd_xfer as a fallback. If v2 is not supported, cmd_xfer
will be NULL, and the code will end up causing a kernel panic.

Add a check for NULL before calling the transfer function, along
with a helpful comment explaining how one might end up in this
situation.

Signed-off-by: Enrico Granata &lt;egranata@chromium.org&gt;
Reviewed-by: Jett Rink &lt;jettrink@chromium.org&gt;
Signed-off-by: Enric Balletbo i Serra &lt;enric.balletbo@collabora.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>platform/chrome: Use proper protocol transfer function</title>
<updated>2018-03-24T09:58:47+00:00</updated>
<author>
<name>Shawn Nematbakhsh</name>
<email>shawnn@chromium.org</email>
</author>
<published>2017-09-08T20:50:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=df9d1861a08f9d2b0b351a58b358ea880a23504d'/>
<id>urn:sha1:df9d1861a08f9d2b0b351a58b358ea880a23504d</id>
<content type='text'>
[ Upstream commit d48b8c58c57f6edbe2965f0a5f62c5cf9593ca96 ]

pkt_xfer should be used for protocol v3, and cmd_xfer otherwise. We had
one instance of these functions correct, but not the second, fall-back
case. We use the fall-back only when the first command returns an
IN_PROGRESS status, which is only used on some EC firmwares where we
don't want to constantly poll the bus, but instead back off and
sleep/retry for a little while.

Fixes: 2c7589af3c4d ("mfd: cros_ec: add proto v3 skeleton")
Signed-off-by: Shawn Nematbakhsh &lt;shawnn@chromium.org&gt;
Signed-off-by: Brian Norris &lt;briannorris@chromium.org&gt;
Reviewed-by: Javier Martinez Canillas &lt;javier@osg.samsung.com&gt;
Signed-off-by: Benson Leung &lt;bleung@chromium.org&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>cros_ec: fix nul-termination for firmware build info</title>
<updated>2018-03-24T09:58:47+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2017-12-04T14:49:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=bcde6355b2617315f611e713c14f6002238d487d'/>
<id>urn:sha1:bcde6355b2617315f611e713c14f6002238d487d</id>
<content type='text'>
[ Upstream commit 50a0d71a5d20e1d3eff1d974fdc8559ad6d74892 ]

As gcc-8 reports, we zero out the wrong byte:

drivers/platform/chrome/cros_ec_sysfs.c: In function 'show_ec_version':
drivers/platform/chrome/cros_ec_sysfs.c:190:12: error: array subscript 4294967295 is above array bounds of 'uint8_t[]' [-Werror=array-bounds]

This changes the code back to what it did before changing to a
zero-length array structure.

Fixes: a841178445bb ("mfd: cros_ec: Use a zero-length array for command data")
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Benson Leung &lt;bleung@chromium.org&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<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.radix-linux.su/kernel/linux.git/commit/?id=d91c348e4c3a011849e309cb76a6fdc714935ea4'/>
<id>urn:sha1: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>
</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.radix-linux.su/kernel/linux.git/commit/?id=69ca969a2626dc4b3bb83b953c053a01e3b9f7e6'/>
<id>urn:sha1: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>
</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.radix-linux.su/kernel/linux.git/commit/?id=ebaf31c46cce0dc8a6ed690b5456b295aa7586a6'/>
<id>urn:sha1: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>
</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.radix-linux.su/kernel/linux.git/commit/?id=18800fc7a04e7df8a345e7ef4fc3064368276f83'/>
<id>urn:sha1: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>
</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.radix-linux.su/kernel/linux.git/commit/?id=f14ae099bdad32414ad968909973bfade9b37967'/>
<id>urn:sha1: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>
</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.radix-linux.su/kernel/linux.git/commit/?id=88dfb8b43d557ee9b1c1ffd2c8d275dd479a66d4'/>
<id>urn:sha1: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>
</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.radix-linux.su/kernel/linux.git/commit/?id=23ecee32b91cf732226bd7a3ee9fa7a9127645ab'/>
<id>urn:sha1: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>
</entry>
</feed>
