Skip to content

Commit 5847680

Browse files
ubiedakartben
authored andcommitted
sensor: adxl367 and adxl372: fix build-failure with streaming mode
These two sensors do not build with asserts enabled as they're referencing a non-existent variable `pkt_size`. Replaced for what (AFAIK) is the intended variable. Signed-off-by: Luis Ubieda <[email protected]>
1 parent c06202c commit 5847680

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

drivers/sensor/adi/adxl367/adxl367_stream.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ static void adxl367_process_fifo_samples_cb(struct rtio *r, const struct rtio_sq
363363

364364
((struct adxl367_fifo_data *)buf)->fifo_byte_count = read_len;
365365

366-
__ASSERT_NO_MSG(read_len % pkt_size == 0);
366+
__ASSERT_NO_MSG(read_len % packet_size == 0);
367367

368368
uint8_t *read_buf = buf + sizeof(*hdr);
369369

drivers/sensor/adi/adxl372/adxl372_stream.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ static void adxl372_process_fifo_samples_cb(struct rtio *r, const struct rtio_sq
249249

250250
((struct adxl372_fifo_data *)buf)->fifo_byte_count = read_len;
251251

252-
__ASSERT_NO_MSG(read_len % pkt_size == 0);
252+
__ASSERT_NO_MSG(read_len % sample_set_size == 0);
253253

254254
uint8_t *read_buf = buf + sizeof(*hdr);
255255

0 commit comments

Comments
 (0)