Skip to content

Commit

Permalink
spi: pxa2xx: Make LPSS SPI general register optional
Browse files Browse the repository at this point in the history
General register located in LPSS SPI private register space is not found in
upcoming Intel LPSS platforms. Access it conditionally depending is it
defined in configuration.

Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Jarkko Nikula authored and Mark Brown committed Jun 5, 2015
1 parent dccf736 commit 82ba2c2
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions drivers/spi/spi-pxa2xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -245,9 +245,13 @@ static void lpss_ssp_setup(struct driver_data *drv_data)
if (drv_data->master_info->enable_dma) {
__lpss_ssp_write_priv(drv_data, config->reg_ssp, 1);

value = __lpss_ssp_read_priv(drv_data, config->reg_general);
value |= GENERAL_REG_RXTO_HOLDOFF_DISABLE;
__lpss_ssp_write_priv(drv_data, config->reg_general, value);
if (config->reg_general >= 0) {
value = __lpss_ssp_read_priv(drv_data,
config->reg_general);
value |= GENERAL_REG_RXTO_HOLDOFF_DISABLE;
__lpss_ssp_write_priv(drv_data,
config->reg_general, value);
}
}
}

Expand Down

0 comments on commit 82ba2c2

Please sign in to comment.