Nikita Yushchenko
e327b2372b
net: ravb: Fix dma_addr_t truncation in error case
...
In ravb_start_xmit(), ravb driver uses u32 variable to store result of
dma_map_single() call. Since ravb hardware has 32-bit address fields in
descriptors, this works properly when mapping is successful - it is
platform's job to provide mapping addresses that fit into hardware
limitations.
However, in failure case dma_map_single() returns DMA_MAPPING_ERROR
constant that is 64-bit when dma_addr_t is 64-bit. Storing this constant
in u32 leads to truncation, and further call to dma_mapping_error()
fails to notice the error.
Fix that by storing result of dma_map_single() in a dma_addr_t
variable.
Fixes: c156633f13 ("Renesas Ethernet AVB driver proper")
Signed-off-by: Nikita Yushchenko <nikita.yoush@cogentembedded.com >
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se >
Reviewed-by: Sergey Shtylyov <s.shtylyov@omp.ru >
Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com >
Signed-off-by: David S. Miller <davem@davemloft.net >
2024-01-14 16:41:51 +00:00
..
2024-01-09 11:18:47 -08:00
2024-01-09 17:07:12 -08:00
2024-01-09 11:18:47 -08:00
2023-12-02 06:27:20 +09:00
2024-01-05 08:04:23 -08:00
2024-01-11 10:07:29 -08:00
2023-11-30 21:21:28 +02:00
2024-01-09 11:18:47 -08:00
2023-12-22 13:00:11 -05:00
2023-11-28 12:57:16 +02:00
2023-10-26 09:42:37 +02:00
2023-11-03 14:51:08 -10:00
2024-01-10 12:23:43 -08:00
2023-12-13 15:26:24 -08:00
2023-11-10 09:23:17 -08:00
2024-01-04 18:06:46 -08:00
2024-01-09 16:32:11 -08:00
2023-12-29 18:08:18 +01:00
2024-01-10 12:23:43 -08:00
2023-12-14 21:54:45 -08:00
2024-01-10 08:45:22 -08:00
2023-12-19 07:58:27 +09:00
2024-01-10 12:23:43 -08:00
2023-11-27 20:00:47 +01:00
2024-01-05 07:58:19 -08:00
2024-01-08 16:03:00 -08:00
2024-01-05 21:28:08 +09:00
2024-01-09 17:11:27 -08:00
2023-11-28 14:08:38 +01:00
2023-12-21 11:19:01 +01:00
2024-01-10 16:43:55 -08:00
2023-12-05 09:10:01 +09:00
2024-01-10 11:03:52 -08:00
2023-10-31 18:32:51 -10:00
2023-11-03 15:44:25 -10:00
2023-12-08 10:36:02 -08:00
2023-11-16 10:00:14 +00:00
2024-01-06 14:10:10 +01:00
2023-11-04 16:25:36 -10:00
2024-01-09 16:32:11 -08:00
2023-12-19 08:08:20 +01:00
2024-01-08 16:32:09 -08:00
2024-01-09 15:02:12 -08:00
2023-12-06 17:00:42 +02:00
2024-01-09 11:18:47 -08:00
2024-01-10 16:43:55 -08:00
2023-10-30 19:09:55 -10:00
2023-12-06 07:36:55 -08:00
2023-11-03 10:07:39 -10:00
2023-11-05 18:45:32 -08:00
2023-10-21 23:04:02 +02:00
2024-01-09 11:18:47 -08:00
2023-12-19 08:23:03 -08:00
2023-11-09 13:37:28 -08:00
2023-10-24 22:36:39 -04:00
2024-01-09 15:02:12 -08:00
2024-01-10 11:03:52 -08:00
2024-01-09 15:02:12 -08:00
2024-01-09 15:40:59 -08:00
2024-01-14 16:41:51 +00:00
2023-11-22 10:55:48 +00:00
2024-01-03 13:33:59 +01:00
2023-12-01 09:51:43 -08:00
2024-01-10 11:03:52 -08:00
2023-12-15 13:15:02 +01:00
2023-12-07 12:22:36 -08:00
2024-01-05 15:55:41 +05:30
2023-11-18 18:59:30 +01:00
2023-12-07 11:10:44 +09:00
2024-01-11 10:07:29 -08:00
2023-11-07 16:40:42 -08:00
2024-01-09 16:12:44 -08:00
2023-12-17 09:19:27 -08:00
2024-01-04 18:06:46 -08:00
2024-01-09 17:07:12 -08:00
2023-12-02 09:01:00 +09:00
2024-01-09 16:12:44 -08:00
2023-11-03 16:00:42 -10:00
2023-12-05 20:51:24 +01:00
2024-01-04 18:06:46 -08:00
2023-11-21 11:09:32 +01:00
2023-12-20 15:02:57 -08:00
2024-01-04 20:02:06 +00:00
2023-11-30 15:02:21 +01:00
2023-10-23 13:11:07 -06:00
2023-11-05 18:49:40 -08:00
2024-01-11 10:07:29 -08:00
2023-12-18 21:09:41 -05:00
2023-10-25 16:50:11 +02:00
2023-11-03 10:07:39 -10:00
2023-11-28 15:27:27 +05:30
2024-01-09 15:02:12 -08:00
2023-11-01 10:02:18 +00:00
2023-10-19 10:26:26 +03:00
2023-11-09 13:47:52 -08:00
2023-12-20 19:26:31 -05:00
2023-12-06 16:15:26 +01:00
2024-01-09 16:20:17 -08:00
2023-12-08 09:03:49 +02:00
2023-12-07 10:48:56 +09:00
2023-12-18 21:09:54 -05:00
2024-01-09 15:02:12 -08:00
2024-01-08 10:26:08 -08:00
2024-01-08 10:26:08 -08:00
2024-01-11 10:07:29 -08:00
2024-01-08 15:27:15 -08:00
2024-01-08 15:42:52 -08:00
2024-01-09 11:18:47 -08:00
2023-10-21 19:19:06 +02:00
2023-11-10 09:19:46 -08:00
2024-01-08 10:26:08 -08:00
2023-11-10 09:19:46 -08:00
2023-11-10 09:19:46 -08:00