Re: [PATCH -next] drm: omapdrm: dss: Remove redundant DSSERR()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 2023/7/27 14:57, Uwe Kleine-König wrote:
> Hello,
> 
> On Thu, Jul 27, 2023 at 11:39:23AM +0000, Ruan Jinjie wrote:
>> There is no need to call the DSSERR() function directly to print
>> a custom message when handling an error from platform_get_irq() function
>> as it is going to display an appropriate error message
>> in case of a failure.
>>
>> Signed-off-by: Ruan Jinjie <ruanjinjie@xxxxxxxxxx>
>> ---
>>  drivers/gpu/drm/omapdrm/dss/dispc.c | 1 -
>>  drivers/gpu/drm/omapdrm/dss/dsi.c   | 4 +---
>>  drivers/gpu/drm/omapdrm/dss/hdmi4.c | 1 -
>>  drivers/gpu/drm/omapdrm/dss/hdmi5.c | 1 -
>>  4 files changed, 1 insertion(+), 6 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/omapdrm/dss/dispc.c b/drivers/gpu/drm/omapdrm/dss/dispc.c
>> index c26aab4939fa..9209103f5dc5 100644
>> --- a/drivers/gpu/drm/omapdrm/dss/dispc.c
>> +++ b/drivers/gpu/drm/omapdrm/dss/dispc.c
>> @@ -4779,7 +4779,6 @@ static int dispc_bind(struct device *dev, struct device *master, void *data)
>>  
>>  	dispc->irq = platform_get_irq(dispc->pdev, 0);
>>  	if (dispc->irq < 0) {
>> -		DSSERR("platform_get_irq failed\n");
>>  		r = -ENODEV;
>>  		goto err_free;
>>  	}
> 
> Orthogonal to your patch I wonder about r = -ENODEV. Wouldn't r =
> dispc->irq be the sensible option? Ditto for the other hunks.

I agree with you, r = dispc->irq will be more sensible!
> 
> Best regards
> Uwe
> 



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux