Re: [PATCH v5 3/4] i2c: tegra: Add logic to support different register offsets

From: Jon Hunter
Date: Fri Jan 09 2026 - 04:53:02 EST



On 08/01/2026 08:53, Jon Hunter wrote:

...

Thinking about this some more I had a tough time reviewing this and feel that this transition is error prone. I would prefer if we kept the current definitions and then just ...

static const struct tegra_i2c_regs tegra20_i2c_regs = {
    .cnfg = I2C_CNFG,
    ...
};

static const struct tegra_i2c_regs tegra20_dvc_i2c_regs = {
    .cnfg = DVC_OFFSET(I2C_CNFG),
    ...
};

static const struct tegra_i2c_regs tegra210_vi_i2c_regs = {
    .cnfg = VI_OFFSET(I2C_CNFG),
    ...
};


I spoke to Thierry and his preference is to get rid of the definitions and use the raw value in the structure. That is fine, but we should make sure these structures are created with the correct data.

Jon

--
nvpublic