Commit b2d8f5ea authored by Manu Abraham's avatar Manu Abraham Committed by Mauro Carvalho Chehab

V4L/DVB (13751): [Mantis] GPIO_CONTROL: Do not toggle GPIO CW's on HIF operations

Signed-off-by: default avatarManu Abraham <manu@linuxtv.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 4d5a28ef
...@@ -142,6 +142,8 @@ struct mantis_pci { ...@@ -142,6 +142,8 @@ struct mantis_pci {
struct mantis_ca *mantis_ca; struct mantis_ca *mantis_ca;
}; };
#define MANTIS_HIF_STATUS (mantis->gpio_status << 12)
extern unsigned int verbose; extern unsigned int verbose;
extern unsigned int devs; extern unsigned int devs;
extern unsigned int i2c; extern unsigned int i2c;
......
...@@ -56,6 +56,7 @@ static int mantis_hif_sbuf_opdone_wait(struct mantis_ca *ca) ...@@ -56,6 +56,7 @@ static int mantis_hif_sbuf_opdone_wait(struct mantis_ca *ca)
return rc; return rc;
} }
int mantis_hif_read_mem(struct mantis_ca *ca, u32 addr) int mantis_hif_read_mem(struct mantis_ca *ca, u32 addr)
{ {
struct mantis_pci *mantis = ca->ca_priv; struct mantis_pci *mantis = ca->ca_priv;
...@@ -67,7 +68,7 @@ int mantis_hif_read_mem(struct mantis_ca *ca, u32 addr) ...@@ -67,7 +68,7 @@ int mantis_hif_read_mem(struct mantis_ca *ca, u32 addr)
hif_addr &= ~MANTIS_GPIF_PCMCIAIOM; hif_addr &= ~MANTIS_GPIF_PCMCIAIOM;
hif_addr |= addr; hif_addr |= addr;
mmwrite(hif_addr, MANTIS_GPIF_BRADDR); mmwrite(hif_addr | MANTIS_HIF_STATUS, MANTIS_GPIF_BRADDR);
mmwrite(count, MANTIS_GPIF_BRBYTES); mmwrite(count, MANTIS_GPIF_BRBYTES);
udelay(20); udelay(20);
...@@ -100,7 +101,7 @@ int mantis_hif_write_mem(struct mantis_ca *ca, u32 addr, u8 data) ...@@ -100,7 +101,7 @@ int mantis_hif_write_mem(struct mantis_ca *ca, u32 addr, u8 data)
mmwrite(slot->slave_cfg, MANTIS_GPIF_CFGSLA); /* Slot0 alone for now */ mmwrite(slot->slave_cfg, MANTIS_GPIF_CFGSLA); /* Slot0 alone for now */
mmwrite(hif_addr, MANTIS_GPIF_ADDR); mmwrite(hif_addr | MANTIS_HIF_STATUS, MANTIS_GPIF_ADDR);
mmwrite(data, MANTIS_GPIF_DOUT); mmwrite(data, MANTIS_GPIF_DOUT);
ca->hif_job_queue = MANTIS_HIF_MEMWR; ca->hif_job_queue = MANTIS_HIF_MEMWR;
...@@ -124,7 +125,7 @@ int mantis_hif_read_iom(struct mantis_ca *ca, u32 addr) ...@@ -124,7 +125,7 @@ int mantis_hif_read_iom(struct mantis_ca *ca, u32 addr)
hif_addr |= MANTIS_GPIF_PCMCIAIOM; hif_addr |= MANTIS_GPIF_PCMCIAIOM;
hif_addr |= addr; hif_addr |= addr;
mmwrite(hif_addr, MANTIS_GPIF_ADDR); mmwrite(hif_addr | MANTIS_HIF_STATUS, MANTIS_GPIF_ADDR);
ca->hif_job_queue = MANTIS_HIF_IOMRD; ca->hif_job_queue = MANTIS_HIF_IOMRD;
if (mantis_hif_sbuf_opdone_wait(ca) != 0) { if (mantis_hif_sbuf_opdone_wait(ca) != 0) {
...@@ -152,7 +153,7 @@ int mantis_hif_write_iom(struct mantis_ca *ca, u32 addr, u8 data) ...@@ -152,7 +153,7 @@ int mantis_hif_write_iom(struct mantis_ca *ca, u32 addr, u8 data)
hif_addr |= MANTIS_GPIF_PCMCIAIOM; hif_addr |= MANTIS_GPIF_PCMCIAIOM;
hif_addr |= addr; hif_addr |= addr;
mmwrite(hif_addr, MANTIS_GPIF_ADDR); mmwrite(hif_addr | MANTIS_HIF_STATUS, MANTIS_GPIF_ADDR);
mmwrite(data, MANTIS_GPIF_DOUT); mmwrite(data, MANTIS_GPIF_DOUT);
ca->hif_job_queue = MANTIS_HIF_IOMWR; ca->hif_job_queue = MANTIS_HIF_IOMWR;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment