Some ST7789V panel integrations rely on the controller reset defaults
or on fixed power sequencing and must not receive the default power
and gamma configuration commands during initialization.
Instead of adding a bypass flag, make the power/gamma/tuning
devicetree properties optional (vcom, gctrl, lcm, gamma, porch-param,
cmd2en-param, pwctrl1-param, pvgam-param, nvgam-param, ram-param,
rgb-param) and only send a configuration command when its property is
present, following the existing vrhs/vdvs handling.
Existing boards set all of these properties, so their initialization
sequence is unchanged.
Signed-off-by: Yeray Lois Sanchez <yerayloissanchez@gmail.com>
Fix formatting issues in the driver class' listfile which caused CI
compliance checks failures.
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
Compatible existence should indeed be checked using the autogenerated
Kconfig option DT_HAS_ST_STM32WBA_IEEE802154_ENABLED as intended by the
code in the listfile; however, in CMake, Kconfig options have the
`CONFIG_` prefix as in C!
Update the listfile to check for compatible existence using the proper
variable (i.e., with the `CONFIG_` prefix).
Signed-off-by: Mathieu Choplain <mathieu.choplain-ext@st.com>
The init sanity check on the DAC_RES status field logged an error but
returned ret, which the preceding successful status read had set to
0, so a failed identity check still reported successful init. Return
-EIO.
Assisted-by: Claude:fable-5
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The driver reports raw controller coordinates straight to INPUT_ABS_X and
INPUT_ABS_Y, so none of the touchscreen-common orientation properties reach
it: a board wiring this part to a rotated or mirrored panel has no way to
describe that in devicetree. Every other touch driver in the tree goes
through input_touchscreen_report_pos().
Route both report paths through the helper and include
touchscreen-common.yaml in the binding. `select INPUT_TOUCH` comes with it:
input_touch.c is gated on that symbol, so without it the helper is never
compiled and the driver fails to link.
Behaviour is unchanged for existing users -- with none of the orientation
properties set the helper passes the coordinates through untouched.
Signed-off-by: Arkadiusz Grzelka <devitwise@gmail.com>
Load the wheel count into a local before the report loop instead of
walking data->touch_instance.p_cfg->num_wheels on every iteration.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Load the slider count into a local before the report loop instead of
walking data->touch_instance.p_cfg->num_sliders on every iteration.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The devicetree-derived button, slider and wheel context tables are only
read, so mark them and their matching config pointer fields const; the
mutable runtime state already lives in separate arrays.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The changed-column mask is loop invariant, so compute it once before the
drive loop instead of reloading last_col_state through the escaped data
pointer on every iteration.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
gpio_qdec_idle_polling_mode() only depends on the static const config,
so evaluate it once and reuse the result for the LED enable and disable
branches.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
analog_axis_num_axes() is defined in another translation unit and cannot
be inlined here, so cache its result in a local instead of calling it on
every loop iteration, matching the save and load helpers.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Replace the byte-at-a-time per-fragment linearization loop with memcpy
and an equivalent up-front bounds check.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Replace the byte-at-a-time copy into the TX DMA buffer with memcpy.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Call synopGMAC_is_last_tx_desc() once and reuse the result instead of
evaluating it twice with identical arguments.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Read the volatile RX descriptor status word once per frame and reuse
it. After OWN reads clear, the descriptor is CPU-owned and stable.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The whole SPI burst buffer was cleared even though the header and
payload are written unconditionally afterwards. Zero only the trailing
pad.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The OA data chunk header is constant across chunks. Compute it once
before the loop instead of on every iteration; the transmitted bytes
are unchanged.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The RX chunk request header is constant across chunks. Compute it once
before the receive loop; the SPI traffic is unchanged.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Replace the three read-modify-write operations on the RX descriptor
address word with one read and write producing the same value.
Assisted-by: Claude:opus-4.8
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
get_status() indexed the channel table before validating the
channel and accepted a channel equal to the channel count, reading
one past the array. Validate first with an exclusive bound like
the other entry points.
Assisted-by: Claude:fable-5
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
In the memory-to-memory path the RX configuration result was
immediately overwritten by the TX call, so a failed RX descriptor
setup was reported as success.
Assisted-by: Claude:fable-5
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
A priority equal to the table size passed the check and read one
entry past the priority table.
Assisted-by: Claude:fable-5
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
ll_i2s_dma_busy() returned true when the transmitter was idle (TX
empty and not busy), the opposite of its name, its H7 branch and
what both callers expect. A STOP or DRAIN issued mid-transfer
disabled the stream immediately, while one issued when idle parked
the stream in STOPPING forever. Return the negated expression.
Assisted-by: Claude:fable-5
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>