Skip to content

Commit 8d19d66

Browse files
Dilip Kotabroonie
authored andcommitted
spi: lantiq: Move interrupt control register offesets to SoC specific data structure
Address of Interrupt control registers are different on new chipsets. So move them to SoC specific data structure. Signed-off-by: Dilip Kota <[email protected]> Link: https://lore.kernel.org/r/f0f9723a30ea9c2ee48d2199f7512af9e15803b0.1594957019.git.eswara.kota@linux.intel.com Signed-off-by: Mark Brown <[email protected]>
1 parent ddf41bf commit 8d19d66

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

drivers/spi/spi-lantiq-ssc.c

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,6 @@
4949
#define LTQ_SPI_RXCNT 0x84
5050
#define LTQ_SPI_DMACON 0xec
5151
#define LTQ_SPI_IRNEN 0xf4
52-
#define LTQ_SPI_IRNICR 0xf8
53-
#define LTQ_SPI_IRNCR 0xfc
5452

5553
#define LTQ_SPI_CLC_SMC_S 16 /* Clock divider for sleep mode */
5654
#define LTQ_SPI_CLC_SMC_M (0xFF << LTQ_SPI_CLC_SMC_S)
@@ -158,8 +156,10 @@
158156
#define LTQ_SPI_IRNEN_ALL 0x1F
159157

160158
struct lantiq_ssc_hwcfg {
161-
unsigned int irnen_r;
162-
unsigned int irnen_t;
159+
unsigned int irnen_r;
160+
unsigned int irnen_t;
161+
unsigned int irncr;
162+
unsigned int irnicr;
163163
};
164164

165165
struct lantiq_ssc_spi {
@@ -792,13 +792,17 @@ static int lantiq_ssc_transfer_one(struct spi_master *master,
792792
}
793793

794794
static const struct lantiq_ssc_hwcfg lantiq_ssc_xway = {
795-
.irnen_r = LTQ_SPI_IRNEN_R_XWAY,
796-
.irnen_t = LTQ_SPI_IRNEN_T_XWAY,
795+
.irnen_r = LTQ_SPI_IRNEN_R_XWAY,
796+
.irnen_t = LTQ_SPI_IRNEN_T_XWAY,
797+
.irnicr = 0xF8,
798+
.irncr = 0xFC,
797799
};
798800

799801
static const struct lantiq_ssc_hwcfg lantiq_ssc_xrx = {
800-
.irnen_r = LTQ_SPI_IRNEN_R_XRX,
801-
.irnen_t = LTQ_SPI_IRNEN_T_XRX,
802+
.irnen_r = LTQ_SPI_IRNEN_R_XRX,
803+
.irnen_t = LTQ_SPI_IRNEN_T_XRX,
804+
.irnicr = 0xF8,
805+
.irncr = 0xFC,
802806
};
803807

804808
static const struct of_device_id lantiq_ssc_match[] = {

0 commit comments

Comments
 (0)