lkml.org 
[lkml]   [2018]   [Jun]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mfd: cros_ec_dev: Don't advertise junk features on failure
On Wed, 30 May 2018, Stephen Boyd wrote:

> If the feature query fails during this driver's probe, we memset the
> features bits to 0, but then we continue to overwrite that with whatever
> junk we read back when the feature probing failed. In the case of a SPI
> device, it may be complete junk, causing the caller of this function to
> think certain features are present when they aren't. Don't copy over the
> bad message on failure so we can fail more gracefully.
>
> Fixes: e4244ebddae2 ("platform/chrome: Introduce a new function to check EC features.")
> Cc: Benson Leung <bleung@chromium.org>
> Cc: Enric Balletbo i Serra <enric.balletbo@collabora.com>
> Cc: Gwendal Grignou <gwendal@chromium.org>
> Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
> Signed-off-by: Stephen Boyd <swboyd@chromium.org>
> ---
> drivers/mfd/cros_ec_dev.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)

Applied, thanks.

--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

\
 
 \ /
  Last update: 2018-06-04 09:46    [W:0.147 / U:0.260 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site