> I think the return value isn't checked at all, so you could
> simply return below "-ENODEV" for all cases (instead of "return ret").
> Then you don't need the e_nodev label and can simplify the flow.
I noticed that the software evolution was continued with an other change
variant.
fbdev:
>> Can it be helpful to distinguish involved error codes better?
>
> No.
I find such a feedback surprising.
May the error code be preserved from a failed call of the function
“fb_alloc_cmap”?
Regards,
Markus
On 5/25/23 07:33, Markus Elfring wrote:
The return value was overlooked from a call of
the function “fb_alloc_cmap”.
* Thus use a corresponding error check.
* Add two jump targets so that a bit of exception handling
can be better reused at the end of this function.
…
+++
>> The return value was overlooked from a call of
>> the function “fb_alloc_cmap”.
>>
>> * Thus use a corresponding error check.
>>
>> * Add two jump targets so that a bit of exception handling
>> can be better reused at the end of this function.
…
>> +++ b/drivers/video/fbdev/imsttfb.c
…
>> @@
On 5/23/23 19:38, Markus Elfring wrote:
From: Markus Elfring
Date: Tue, 23 May 2023 14:32:39 +0200
The return value was overlooked from a call of
the function “fb_alloc_cmap”.
* Thus use a corresponding error check.
* Add two jump targets so that a bit of exception handling
can be better
From: Markus Elfring
Date: Tue, 23 May 2023 14:32:39 +0200
The return value was overlooked from a call of
the function “fb_alloc_cmap”.
* Thus use a corresponding error check.
* Add two jump targets so that a bit of exception handling
can be better reused at the end of this function.