Messages in this thread | | | From | David Laight <> | Subject | RE: [PATCH] ARC: io.h: Implement reads{x}()/writes{x}() | Date | Thu, 29 Nov 2018 12:47:59 +0000 |
| |
From: Jose Abreu > Sent: 29 November 2018 12:42 > > Some ARC CPU's do not support unaligned loads/stores. Currently, generic > implementation of reads{b/w/l}()/writes{b/w/l}() is being used with ARC. > This can lead to misfunction of some drivers as generic functions do a > plain dereference of a pointer that can be unaligned. > > Let's use {get/put}_unaligned() helper instead of plain dereference of > pointer in order to fix this.
Is it worth adding a check for the pointer being aligned?
David
- Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK Registration No: 1397386 (Wales)
| |