summaryrefslogtreecommitdiff
path: root/drivers/isdn
diff options
context:
space:
mode:
authorRichard Knutsson <ricknu-0@student.ltu.se>2007-02-12 00:53:25 -0800
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-12 09:48:35 -0800
commita871fe858c5437ff8798fbaef52b6a88110b64a1 (patch)
tree2e93927962c087c48b371c3494550f4c27e74a25 /drivers/isdn
parent986c4bb8c4a7bf248378954782553334a003d80a (diff)
[PATCH] drivers/isdn/hisax/: Convert to generic boolean-values
Signed-off-by: Richard Knutsson <ricknu-0@student.ltu.se> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/isdn')
-rw-r--r--drivers/isdn/hisax/hfc_usb.c40
-rw-r--r--drivers/isdn/hisax/hfc_usb.h3
2 files changed, 20 insertions, 23 deletions
diff --git a/drivers/isdn/hisax/hfc_usb.c b/drivers/isdn/hisax/hfc_usb.c
index 5a6989f23fcf..42bbae2a646c 100644
--- a/drivers/isdn/hisax/hfc_usb.c
+++ b/drivers/isdn/hisax/hfc_usb.c
@@ -183,7 +183,7 @@ typedef struct hfcusb_data {
int vend_idx; /* vendor found */
int b_mode[2]; /* B-channel mode */
int l1_activated; /* layer 1 activated */
- int disc_flag; /* TRUE if device was disonnected to avoid some USB actions */
+ int disc_flag; /* 'true' if device was disonnected to avoid some USB actions */
int packet_size, iso_packet_size;
/* control pipe background handling */
@@ -392,7 +392,7 @@ l1_timer_expire_t3(hfcusb_data * hfc)
DBG(ISDN_DBG,
"HFC-S USB: PH_DEACTIVATE | INDICATION sent (T3 expire)");
#endif
- hfc->l1_activated = FALSE;
+ hfc->l1_activated = false;
handle_led(hfc, LED_S0_OFF);
/* deactivate : */
queue_control_request(hfc, HFCUSB_STATES, 0x10, 1);
@@ -411,7 +411,7 @@ l1_timer_expire_t4(hfcusb_data * hfc)
DBG(ISDN_DBG,
"HFC-S USB: PH_DEACTIVATE | INDICATION sent (T4 expire)");
#endif
- hfc->l1_activated = FALSE;
+ hfc->l1_activated = false;
handle_led(hfc, LED_S0_OFF);
}
@@ -452,7 +452,7 @@ state_handler(hfcusb_data * hfc, __u8 state)
#ifdef CONFIG_HISAX_DEBUG
DBG(ISDN_DBG, "HFC-S USB: PH_ACTIVATE | INDICATION sent");
#endif
- hfc->l1_activated = TRUE;
+ hfc->l1_activated = true;
handle_led(hfc, LED_S0_ON);
} else if (state <= 3 /* && activated */ ) {
if (old_state == 7 || old_state == 8) {
@@ -472,7 +472,7 @@ state_handler(hfcusb_data * hfc, __u8 state)
DBG(ISDN_DBG,
"HFC-S USB: PH_DEACTIVATE | INDICATION sent");
#endif
- hfc->l1_activated = FALSE;
+ hfc->l1_activated = false;
handle_led(hfc, LED_S0_OFF);
}
}
@@ -622,7 +622,7 @@ tx_iso_complete(struct urb *urb)
if (fifo->active && !status) {
transp_mode = 0;
if (fifon < 4 && hfc->b_mode[fifon / 2] == L1_MODE_TRANS)
- transp_mode = TRUE;
+ transp_mode = true;
/* is FifoFull-threshold set for our channel? */
threshbit = threshtable[fifon] & hfc->threshold_mask;
@@ -640,7 +640,7 @@ tx_iso_complete(struct urb *urb)
tx_iso_complete, urb->context);
memset(context_iso_urb->buffer, 0,
sizeof(context_iso_urb->buffer));
- frame_complete = FALSE;
+ frame_complete = false;
/* Generate next Iso Packets */
for (k = 0; k < num_isoc_packets; ++k) {
if (fifo->skbuff) {
@@ -666,7 +666,7 @@ tx_iso_complete(struct urb *urb)
/* add 2 byte flags and 16bit CRC at end of ISDN frame */
fifo->bit_line += 32;
}
- frame_complete = TRUE;
+ frame_complete = true;
}
memcpy(context_iso_urb->buffer +
@@ -693,7 +693,7 @@ tx_iso_complete(struct urb *urb)
}
if (frame_complete) {
- fifo->delete_flg = TRUE;
+ fifo->delete_flg = true;
fifo->hif->l1l2(fifo->hif,
PH_DATA | CONFIRM,
(void *) (unsigned long) fifo->skbuff->
@@ -701,9 +701,9 @@ tx_iso_complete(struct urb *urb)
if (fifo->skbuff && fifo->delete_flg) {
dev_kfree_skb_any(fifo->skbuff);
fifo->skbuff = NULL;
- fifo->delete_flg = FALSE;
+ fifo->delete_flg = false;
}
- frame_complete = FALSE;
+ frame_complete = false;
}
}
errcode = usb_submit_urb(urb, GFP_ATOMIC);
@@ -837,7 +837,7 @@ collect_rx_frame(usb_fifo * fifo, __u8 * data, int len, int finish)
fifon = fifo->fifonum;
transp_mode = 0;
if (fifon < 4 && hfc->b_mode[fifon / 2] == L1_MODE_TRANS)
- transp_mode = TRUE;
+ transp_mode = true;
if (!fifo->skbuff) {
fifo->skbuff = dev_alloc_skb(fifo->max_size + 3);
@@ -1176,7 +1176,7 @@ hfc_usb_l2l1(struct hisax_if *my_hisax_if, int pr, void *arg)
if (fifo->skbuff && fifo->delete_flg) {
dev_kfree_skb_any(fifo->skbuff);
fifo->skbuff = NULL;
- fifo->delete_flg = FALSE;
+ fifo->delete_flg = false;
}
fifo->skbuff = arg; /* we have a new buffer */
break;
@@ -1262,8 +1262,8 @@ usb_init(hfcusb_data * hfc)
hfc->b_mode[0] = L1_MODE_NULL;
hfc->b_mode[1] = L1_MODE_NULL;
- hfc->l1_activated = FALSE;
- hfc->disc_flag = FALSE;
+ hfc->l1_activated = false;
+ hfc->disc_flag = false;
hfc->led_state = 0;
hfc->led_new_data = 0;
hfc->old_led_state = 0;
@@ -1404,7 +1404,7 @@ hfc_usb_probe(struct usb_interface *intf, const struct usb_device_id *id)
/* check for config EOL element */
while (validconf[cfg_used][0]) {
- cfg_found = TRUE;
+ cfg_found = true;
vcf = validconf[cfg_used];
/* first endpoint descriptor */
ep = iface->endpoint;
@@ -1426,7 +1426,7 @@ hfc_usb_probe(struct usb_interface *intf, const struct usb_device_id *id)
idx++;
attr = ep->desc.bmAttributes;
if (cmptbl[idx] == EP_NUL) {
- cfg_found = FALSE;
+ cfg_found = false;
}
if (attr == USB_ENDPOINT_XFER_INT
&& cmptbl[idx] == EP_INT)
@@ -1448,7 +1448,7 @@ hfc_usb_probe(struct usb_interface *intf, const struct usb_device_id *id)
"HFC-S USB: Interrupt Endpoint interval < %d found - skipping config",
vcf[17]);
#endif
- cfg_found = FALSE;
+ cfg_found = false;
}
ep++;
}
@@ -1456,7 +1456,7 @@ hfc_usb_probe(struct usb_interface *intf, const struct usb_device_id *id)
/* all entries must be EP_NOP or EP_NUL for a valid config */
if (cmptbl[i] != EP_NOP
&& cmptbl[i] != EP_NUL)
- cfg_found = FALSE;
+ cfg_found = false;
}
if (cfg_found) {
if (cfg_used < small_match) {
@@ -1656,7 +1656,7 @@ hfc_usb_disconnect(struct usb_interface
hfcusb_data *context = usb_get_intfdata(intf);
int i;
printk(KERN_INFO "HFC-S USB: device disconnect\n");
- context->disc_flag = TRUE;
+ context->disc_flag = true;
usb_set_intfdata(intf, NULL);
if (!context)
return;
diff --git a/drivers/isdn/hisax/hfc_usb.h b/drivers/isdn/hisax/hfc_usb.h
index 6349367ed480..471f2354dfde 100644
--- a/drivers/isdn/hisax/hfc_usb.h
+++ b/drivers/isdn/hisax/hfc_usb.h
@@ -12,9 +12,6 @@
#define VERBOSE_USB_DEBUG
-#define TRUE 1
-#define FALSE 0
-
/***********/
/* defines */