lkml.org 
[lkml]   [2021]   [Sep]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] Input: cyttsp - Make use of the helper function dev_err_probe()
Hi Cai,

On Thu, Sep 16, 2021 at 5:32 PM Cai Huoqing <caihuoqing@baidu.com> wrote:

> if (IS_ERR(ts->reset_gpio)) {
> error = PTR_ERR(ts->reset_gpio);
> - dev_err(dev, "Failed to request reset gpio, error %d\n", error);
> + dev_err_probe(dev, error, "Failed to request reset gpio\n");
> return ERR_PTR(error);

In this case you're supposed to do

return dev_err_probe(dev, error, "Failed to request reset gpio\n");

Yours,
Linus Walleij

\
 
 \ /
  Last update: 2021-09-17 00:30    [W:0.051 / U:0.360 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site