Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tbsecp3: fix compiler warnings #299

Open
wants to merge 2 commits into
base: latest
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 12 additions & 14 deletions drivers/media/pci/tbsecp3/tbsecp3-dvb.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ static int tbs6302se_read_mac(struct tbsecp3_adapter *adap)
//printk(" the receiver always busy !\n");
//check mcu status
*(u32 *)tmpbuf = tbs_read( BASE_ADDRESS_24CXX, STATUS_MAC16_24CXX );
if((tmpbuf[0]&0x4) == 1) // bit2==1 mcu busy
if((tmpbuf[0]&0x4) != 0) // bit2==1 mcu busy
{
//printk("MCU status is busy!!!\n" );
// release cs;
Expand Down Expand Up @@ -241,7 +241,7 @@ static int tbs6304_read_mac(struct tbsecp3_adapter *adap)
//printk(" the receiver always busy !\n");
//check mcu status
*(u32 *)tmpbuf = tbs_read( BASE_ADDRESS_24CXX, STATUS_MAC16_24CXX );
if((tmpbuf[0]&0x4) == 1) // bit2==1 mcu busy
if((tmpbuf[0]&0x4) != 0) // bit2==1 mcu busy
{
//printk("MCU status is busy!!!\n" );
// release cs;
Expand Down Expand Up @@ -347,7 +347,7 @@ static int tbs6308_read_mac_ext(struct tbsecp3_adapter *adap)
ret = 0;
//check mcu status
*(u32 *)tmpbuf = tbs_read_ext(adap, BASE_ADDRESS_24CXX, STATUS_MAC16_24CXX );
if((tmpbuf[0]&0x4) == 1) // bit2==1 mcu busy
if((tmpbuf[0]&0x4) != 0) // bit2==1 mcu busy
{
//printk("MCU status is busy!!!\n" );
// release cs;
Expand Down Expand Up @@ -410,7 +410,7 @@ static void tbs6301_read_mac(struct tbsecp3_adapter *adap)
printk(" the receiver always busy !\n");
//check mcu status
*(u32 *)tmpbuf = tbs_read( BASE_ADDRESS_24CXX, STATUS_MAC16_24CXX );
if((tmpbuf[0]&0x4) == 1) // bit2==1 mcu busy
if((tmpbuf[0]&0x4) != 0) // bit2==1 mcu busy
{
printk("MCU status is busy!!!\n" );
// release cs;
Expand Down Expand Up @@ -1581,16 +1581,14 @@ static int tbsecp3_frontend_attach(struct tbsecp3_adapter *adapter)
adapter->fe = dvb_attach(tas2971_attach, &tbs6308_demod_cfg, i2c);
if (adapter->fe == NULL)
goto frontend_atach_fail;
if(adapter->nr <4)
{
if(tbs6304_read_mac(adapter)==0)
tbs6304_read_mac(adapter);
}
else
{
if(tbs6308_read_mac_ext(adapter)==0)
tbs6308_read_mac_ext(adapter);//try again
}

if(adapter->nr < 4) {
if(tbs6304_read_mac(adapter)==0)
tbs6304_read_mac(adapter);
} else {
if(tbs6308_read_mac_ext(adapter)==0)
tbs6308_read_mac_ext(adapter);//try again
}
break;

case TBSECP3_BOARD_TBS6304:
Expand Down