can-utils/mcp251xfd
Marc Kleine-Budde aa902ae2af mcp251xfd: mcp251xfd_regmap_read(): don't assign return value of strchr() to `char *`
The `file_path` of `strchr(file_path, '/')` is a `const char *`. In this
case the `strchr()` in debian experimental returns a `const char *`,
leading to this error message:

```
mcp251xfd/mcp251xfd-regmap.c:75:13: error: assignment discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers]
   75 |         tmp = strchr(file_path, '/');
      |             ^
```

Fix the error by using the return value from `strchr()` directly in the
`if()`.

Link: https://github.com/linux-can/can-utils/actions/runs/22649777324/job/65679726209?pr=619
2026-03-04 11:35:38 +01:00
..
data mcp251xfd-dump: add test data 2023-01-03 20:31:54 +01:00
99-devcoredump.rules mcp251xfd: add sample dev-coredump udev rule 2021-02-13 23:36:43 +01:00
devcoredump mcp251xfd: add sample dev-coredump udev rule 2021-02-13 23:36:43 +01:00
mcp251xfd-dev-coredump.c mcp251xfd-dump: add support for dumps created with Linux kernel >= v5.18 2023-01-03 20:31:54 +01:00
mcp251xfd-dump-userspace.h mcp251xfd-dump: add support for dumps created with Linux kernel >= v5.18 2023-01-03 20:31:54 +01:00
mcp251xfd-dump.c mcp251xfd-dump: add support for dumps created with Linux kernel >= v5.18 2023-01-03 20:31:54 +01:00
mcp251xfd-dump.h mcp251xfd-dump: add tool to decode chip and driver state of mcp251xfd 2021-02-13 23:36:43 +01:00
mcp251xfd-gen-testdata.sh mcp251xfd-gen-testdata: add script to generate mcp251xfd-dump data 2023-01-03 20:18:47 +01:00
mcp251xfd-main.c mcp251xfd-dump: add support for dumps created with Linux kernel >= v5.18 2023-01-03 20:31:54 +01:00
mcp251xfd-regmap.c mcp251xfd: mcp251xfd_regmap_read(): don't assign return value of strchr() to `char *` 2026-03-04 11:35:38 +01:00
mcp251xfd.h mcp251xfd-dump: add tool to decode chip and driver state of mcp251xfd 2021-02-13 23:36:43 +01:00