if ((sq == 0) && (dq == 0) && (lq == 0)) {
for (i = 0; i < lb; i++)
*dst++ = *src++;
- return (uint8_t *)_dst;
+ return _dst;
}
/* fallback to slow bit copy */
}
}
- return (uint8_t *)_dst;
+ return _dst;
}
uint32_t flip_u32(uint32_t value, unsigned int num)
static inline void buf_set_u32(void *_buffer,
unsigned first, unsigned num, uint32_t value)
{
- uint8_t *buffer = (uint8_t *)_buffer;
+ uint8_t *buffer = _buffer;
if ((num == 32) && (first == 0)) {
buffer[3] = (value >> 24) & 0xff;
static inline void buf_set_u64(void *_buffer,
unsigned first, unsigned num, uint64_t value)
{
- uint8_t *buffer = (uint8_t *)_buffer;
+ uint8_t *buffer = _buffer;
if ((num == 32) && (first == 0)) {
buffer[3] = (value >> 24) & 0xff;
static inline uint32_t buf_get_u32(const void *_buffer,
unsigned first, unsigned num)
{
- uint8_t *buffer = (uint8_t *)_buffer;
+ const uint8_t *buffer = _buffer;
if ((num == 32) && (first == 0)) {
return (((uint32_t)buffer[3]) << 24) |
static inline uint64_t buf_get_u64(const void *_buffer,
unsigned first, unsigned num)
{
- uint8_t *buffer = (uint8_t *)_buffer;
+ const uint8_t *buffer = _buffer;
if ((num == 32) && (first == 0)) {
return 0 + ((((uint32_t)buffer[3]) << 24) | /* Note - zero plus is to avoid a checkpatch bug */