aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/saa7134
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/saa7134')
-rw-r--r--drivers/media/video/saa7134/saa7134-i2c.c24
-rw-r--r--drivers/media/video/saa7134/saa7134.h6
2 files changed, 12 insertions, 18 deletions
diff --git a/drivers/media/video/saa7134/saa7134-i2c.c b/drivers/media/video/saa7134/saa7134-i2c.c
index 6f9fe86fed98..cce8da6a4f94 100644
--- a/drivers/media/video/saa7134/saa7134-i2c.c
+++ b/drivers/media/video/saa7134/saa7134-i2c.c
@@ -120,9 +120,9 @@ static inline int i2c_is_error(enum i2c_status status)
120 case ARB_LOST: 120 case ARB_LOST:
121 case SEQ_ERR: 121 case SEQ_ERR:
122 case ST_ERR: 122 case ST_ERR:
123 return TRUE; 123 return true;
124 default: 124 default:
125 return FALSE; 125 return false;
126 } 126 }
127} 127}
128 128
@@ -131,9 +131,9 @@ static inline int i2c_is_idle(enum i2c_status status)
131 switch (status) { 131 switch (status) {
132 case IDLE: 132 case IDLE:
133 case DONE_STOP: 133 case DONE_STOP:
134 return TRUE; 134 return true;
135 default: 135 default:
136 return FALSE; 136 return false;
137 } 137 }
138} 138}
139 139
@@ -141,9 +141,9 @@ static inline int i2c_is_busy(enum i2c_status status)
141{ 141{
142 switch (status) { 142 switch (status) {
143 case BUSY: 143 case BUSY:
144 return TRUE; 144 return true;
145 default: 145 default:
146 return FALSE; 146 return false;
147 } 147 }
148} 148}
149 149
@@ -159,8 +159,8 @@ static int i2c_is_busy_wait(struct saa7134_dev *dev)
159 saa_wait(I2C_WAIT_DELAY); 159 saa_wait(I2C_WAIT_DELAY);
160 } 160 }
161 if (I2C_WAIT_RETRY == count) 161 if (I2C_WAIT_RETRY == count)
162 return FALSE; 162 return false;
163 return TRUE; 163 return true;
164} 164}
165 165
166static int i2c_reset(struct saa7134_dev *dev) 166static int i2c_reset(struct saa7134_dev *dev)
@@ -171,7 +171,7 @@ static int i2c_reset(struct saa7134_dev *dev)
171 d2printk(KERN_DEBUG "%s: i2c reset\n",dev->name); 171 d2printk(KERN_DEBUG "%s: i2c reset\n",dev->name);
172 status = i2c_get_status(dev); 172 status = i2c_get_status(dev);
173 if (!i2c_is_error(status)) 173 if (!i2c_is_error(status))
174 return TRUE; 174 return true;
175 i2c_set_status(dev,status); 175 i2c_set_status(dev,status);
176 176
177 for (count = 0; count < I2C_WAIT_RETRY; count++) { 177 for (count = 0; count < I2C_WAIT_RETRY; count++) {
@@ -181,13 +181,13 @@ static int i2c_reset(struct saa7134_dev *dev)
181 udelay(I2C_WAIT_DELAY); 181 udelay(I2C_WAIT_DELAY);
182 } 182 }
183 if (I2C_WAIT_RETRY == count) 183 if (I2C_WAIT_RETRY == count)
184 return FALSE; 184 return false;
185 185
186 if (!i2c_is_idle(status)) 186 if (!i2c_is_idle(status))
187 return FALSE; 187 return false;
188 188
189 i2c_set_attr(dev,NOP); 189 i2c_set_attr(dev,NOP);
190 return TRUE; 190 return true;
191} 191}
192 192
193static inline int i2c_send_byte(struct saa7134_dev *dev, 193static inline int i2c_send_byte(struct saa7134_dev *dev,
diff --git a/drivers/media/video/saa7134/saa7134.h b/drivers/media/video/saa7134/saa7134.h
index 2ad859bda2e3..b3e3957c89b5 100644
--- a/drivers/media/video/saa7134/saa7134.h
+++ b/drivers/media/video/saa7134/saa7134.h
@@ -45,12 +45,6 @@
45#include <media/video-buf-dvb.h> 45#include <media/video-buf-dvb.h>
46#endif 46#endif
47 47
48#ifndef TRUE
49# define TRUE (1==1)
50#endif
51#ifndef FALSE
52# define FALSE (1==0)
53#endif
54#define UNSET (-1U) 48#define UNSET (-1U)
55 49
56/* ----------------------------------------------------------- */ 50/* ----------------------------------------------------------- */