Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[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>

authored by

Richard Knutsson and committed by
Linus Torvalds
a871fe85 986c4bb8

+20 -23
+20 -20
drivers/isdn/hisax/hfc_usb.c
··· 183 183 int vend_idx; /* vendor found */ 184 184 int b_mode[2]; /* B-channel mode */ 185 185 int l1_activated; /* layer 1 activated */ 186 - int disc_flag; /* TRUE if device was disonnected to avoid some USB actions */ 186 + int disc_flag; /* 'true' if device was disonnected to avoid some USB actions */ 187 187 int packet_size, iso_packet_size; 188 188 189 189 /* control pipe background handling */ ··· 392 392 DBG(ISDN_DBG, 393 393 "HFC-S USB: PH_DEACTIVATE | INDICATION sent (T3 expire)"); 394 394 #endif 395 - hfc->l1_activated = FALSE; 395 + hfc->l1_activated = false; 396 396 handle_led(hfc, LED_S0_OFF); 397 397 /* deactivate : */ 398 398 queue_control_request(hfc, HFCUSB_STATES, 0x10, 1); ··· 411 411 DBG(ISDN_DBG, 412 412 "HFC-S USB: PH_DEACTIVATE | INDICATION sent (T4 expire)"); 413 413 #endif 414 - hfc->l1_activated = FALSE; 414 + hfc->l1_activated = false; 415 415 handle_led(hfc, LED_S0_OFF); 416 416 } 417 417 ··· 452 452 #ifdef CONFIG_HISAX_DEBUG 453 453 DBG(ISDN_DBG, "HFC-S USB: PH_ACTIVATE | INDICATION sent"); 454 454 #endif 455 - hfc->l1_activated = TRUE; 455 + hfc->l1_activated = true; 456 456 handle_led(hfc, LED_S0_ON); 457 457 } else if (state <= 3 /* && activated */ ) { 458 458 if (old_state == 7 || old_state == 8) { ··· 472 472 DBG(ISDN_DBG, 473 473 "HFC-S USB: PH_DEACTIVATE | INDICATION sent"); 474 474 #endif 475 - hfc->l1_activated = FALSE; 475 + hfc->l1_activated = false; 476 476 handle_led(hfc, LED_S0_OFF); 477 477 } 478 478 } ··· 622 622 if (fifo->active && !status) { 623 623 transp_mode = 0; 624 624 if (fifon < 4 && hfc->b_mode[fifon / 2] == L1_MODE_TRANS) 625 - transp_mode = TRUE; 625 + transp_mode = true; 626 626 627 627 /* is FifoFull-threshold set for our channel? */ 628 628 threshbit = threshtable[fifon] & hfc->threshold_mask; ··· 640 640 tx_iso_complete, urb->context); 641 641 memset(context_iso_urb->buffer, 0, 642 642 sizeof(context_iso_urb->buffer)); 643 - frame_complete = FALSE; 643 + frame_complete = false; 644 644 /* Generate next Iso Packets */ 645 645 for (k = 0; k < num_isoc_packets; ++k) { 646 646 if (fifo->skbuff) { ··· 666 666 /* add 2 byte flags and 16bit CRC at end of ISDN frame */ 667 667 fifo->bit_line += 32; 668 668 } 669 - frame_complete = TRUE; 669 + frame_complete = true; 670 670 } 671 671 672 672 memcpy(context_iso_urb->buffer + ··· 693 693 } 694 694 695 695 if (frame_complete) { 696 - fifo->delete_flg = TRUE; 696 + fifo->delete_flg = true; 697 697 fifo->hif->l1l2(fifo->hif, 698 698 PH_DATA | CONFIRM, 699 699 (void *) (unsigned long) fifo->skbuff-> ··· 701 701 if (fifo->skbuff && fifo->delete_flg) { 702 702 dev_kfree_skb_any(fifo->skbuff); 703 703 fifo->skbuff = NULL; 704 - fifo->delete_flg = FALSE; 704 + fifo->delete_flg = false; 705 705 } 706 - frame_complete = FALSE; 706 + frame_complete = false; 707 707 } 708 708 } 709 709 errcode = usb_submit_urb(urb, GFP_ATOMIC); ··· 837 837 fifon = fifo->fifonum; 838 838 transp_mode = 0; 839 839 if (fifon < 4 && hfc->b_mode[fifon / 2] == L1_MODE_TRANS) 840 - transp_mode = TRUE; 840 + transp_mode = true; 841 841 842 842 if (!fifo->skbuff) { 843 843 fifo->skbuff = dev_alloc_skb(fifo->max_size + 3); ··· 1176 1176 if (fifo->skbuff && fifo->delete_flg) { 1177 1177 dev_kfree_skb_any(fifo->skbuff); 1178 1178 fifo->skbuff = NULL; 1179 - fifo->delete_flg = FALSE; 1179 + fifo->delete_flg = false; 1180 1180 } 1181 1181 fifo->skbuff = arg; /* we have a new buffer */ 1182 1182 break; ··· 1262 1262 hfc->b_mode[0] = L1_MODE_NULL; 1263 1263 hfc->b_mode[1] = L1_MODE_NULL; 1264 1264 1265 - hfc->l1_activated = FALSE; 1266 - hfc->disc_flag = FALSE; 1265 + hfc->l1_activated = false; 1266 + hfc->disc_flag = false; 1267 1267 hfc->led_state = 0; 1268 1268 hfc->led_new_data = 0; 1269 1269 hfc->old_led_state = 0; ··· 1404 1404 1405 1405 /* check for config EOL element */ 1406 1406 while (validconf[cfg_used][0]) { 1407 - cfg_found = TRUE; 1407 + cfg_found = true; 1408 1408 vcf = validconf[cfg_used]; 1409 1409 /* first endpoint descriptor */ 1410 1410 ep = iface->endpoint; ··· 1426 1426 idx++; 1427 1427 attr = ep->desc.bmAttributes; 1428 1428 if (cmptbl[idx] == EP_NUL) { 1429 - cfg_found = FALSE; 1429 + cfg_found = false; 1430 1430 } 1431 1431 if (attr == USB_ENDPOINT_XFER_INT 1432 1432 && cmptbl[idx] == EP_INT) ··· 1448 1448 "HFC-S USB: Interrupt Endpoint interval < %d found - skipping config", 1449 1449 vcf[17]); 1450 1450 #endif 1451 - cfg_found = FALSE; 1451 + cfg_found = false; 1452 1452 } 1453 1453 ep++; 1454 1454 } ··· 1456 1456 /* all entries must be EP_NOP or EP_NUL for a valid config */ 1457 1457 if (cmptbl[i] != EP_NOP 1458 1458 && cmptbl[i] != EP_NUL) 1459 - cfg_found = FALSE; 1459 + cfg_found = false; 1460 1460 } 1461 1461 if (cfg_found) { 1462 1462 if (cfg_used < small_match) { ··· 1656 1656 hfcusb_data *context = usb_get_intfdata(intf); 1657 1657 int i; 1658 1658 printk(KERN_INFO "HFC-S USB: device disconnect\n"); 1659 - context->disc_flag = TRUE; 1659 + context->disc_flag = true; 1660 1660 usb_set_intfdata(intf, NULL); 1661 1661 if (!context) 1662 1662 return;
-3
drivers/isdn/hisax/hfc_usb.h
··· 12 12 13 13 #define VERBOSE_USB_DEBUG 14 14 15 - #define TRUE 1 16 - #define FALSE 0 17 - 18 15 19 16 /***********/ 20 17 /* defines */