[1/1] eal/linux: Remove unused values
Checks
Commit Message
Found by static analysis:
In dev_uev_socket_fd_create(), fd is assigned before a return,
and not used.
The same for the variables buf and i in dev_uev_parse().
Fixes: c2bd9367e18f ("lib: remove direct access to interrupt handle")
Fixes: 0d0f478d0483 ("eal/linux: add uevent parse and process")
Signed-off-by: Ariel Otilibili <ariel.otilibili@6wind.com>
---
lib/eal/linux/eal_dev.c | 3 ---
1 file changed, 3 deletions(-)
Comments
13/01/2025 18:19, Ariel Otilibili:
> Found by static analysis:
>
> In dev_uev_socket_fd_create(), fd is assigned before a return,
> and not used.
>
> The same for the variables buf and i in dev_uev_parse().
>
> Fixes: c2bd9367e18f ("lib: remove direct access to interrupt handle")
> Fixes: 0d0f478d0483 ("eal/linux: add uevent parse and process")
>
> Signed-off-by: Ariel Otilibili <ariel.otilibili@6wind.com>
Applied, thanks.
Hi Thomas,
On Wed, Feb 12, 2025 at 3:00 PM Thomas Monjalon <thomas@monjalon.net> wrote:
> Applied, thanks.
>
Thanks for the feedback. Have a good day.
Ariel
@@ -129,7 +129,6 @@ dev_uev_socket_fd_create(void)
return 0;
err:
close(fd);
- fd = -1;
return ret;
}
@@ -165,8 +164,6 @@ dev_uev_parse(const char *buf, struct rte_dev_event *event, int length)
* uevent from udev.
*/
if (!strncmp(buf, "libudev", 7)) {
- buf += 7;
- i += 7;
return -1;
}
if (!strncmp(buf, "ACTION=", 7)) {