serial_8250.h
上传用户:lgb322
上传日期:2013-02-24
资源大小:30529k
文件大小:2k
源码类别:

嵌入式Linux

开发平台:

Unix_Linux

  1. /*
  2.  *  linux/drivers/char/serial_8250.h
  3.  *
  4.  *  Driver for 8250/16550-type serial ports
  5.  *
  6.  *  Based on drivers/char/serial.c, by Linus Torvalds, Theodore Ts'o.
  7.  *
  8.  *  Copyright (C) 2001 Russell King.
  9.  *
  10.  * This program is free software; you can redistribute it and/or modify
  11.  * it under the terms of the GNU General Public License as published by
  12.  * the Free Software Foundation; either version 2 of the License, or
  13.  * (at your option) any later version.
  14.  *
  15.  *  $Id: serial_8250.h,v 1.1.1.1 2001/07/08 22:07:04 rmk Exp $
  16.  */
  17. struct serial8250_probe {
  18. struct module *owner;
  19. int (*pci_init_one)(struct pci_dev *dev);
  20. void (*pci_remove_one)(struct pci_dev *dev);
  21. void (*pnp_init)(void);
  22. };
  23. int serial8250_register_probe(struct serial8250_probe *probe);
  24. void serial8250_unregister_probe(struct serial8250_probe *probe);
  25. struct old_serial_port {
  26. unsigned int uart;
  27. unsigned int base_baud;
  28. unsigned int port;
  29. unsigned int irq;
  30. unsigned int flags;
  31. };
  32. #undef SERIAL_PARANOIA_CHECK
  33. #define CONFIG_SERIAL_NOPAUSE_IO
  34. #define SERIAL_DO_RESTART
  35. #ifdef CONFIG_PCI
  36. #ifndef CONFIG_SERIAL_SHARE_IRQ
  37. #define CONFIG_SERIAL_SHARE_IRQ
  38. #endif
  39. #ifndef CONFIG_SERIAL_MANY_PORTS
  40. #define CONFIG_SERIAL_MANY_PORTS
  41. #endif
  42. #endif
  43. #if defined(CONFIG_ISAPNP)|| (defined(CONFIG_ISAPNP_MODULE) && defined(MODULE))
  44. #ifndef ENABLE_SERIAL_PNP
  45. #define ENABLE_SERIAL_PNP
  46. #endif
  47. #endif
  48. /* Set of debugging defines */
  49. #undef SERIAL_DEBUG_INTR
  50. #undef SERIAL_DEBUG_PCI
  51. #undef SERIAL_DEBUG_AUTOCONF
  52. /* Sanity checks */
  53. #ifdef CONFIG_SERIAL_MULTIPORT
  54. #ifndef CONFIG_SERIAL_SHARE_IRQ
  55. #define CONFIG_SERIAL_SHARE_IRQ
  56. #endif
  57. #endif
  58. #ifdef CONFIG_HUB6
  59. #ifndef CONFIG_SERIAL_MANY_PORTS
  60. #define CONFIG_SERIAL_MANY_PORTS
  61. #endif
  62. #ifndef CONFIG_SERIAL_SHARE_IRQ
  63. #define CONFIG_SERIAL_SHARE_IRQ
  64. #endif
  65. #endif
  66. #ifdef MODULE
  67. #undef CONFIG_SERIAL_CONSOLE
  68. #endif
  69. #define CONFIG_SERIAL_RSA
  70. #define RS_ISR_PASS_LIMIT 256
  71. #if defined(__i386__) && (defined(CONFIG_M386) || defined(CONFIG_M486))
  72. #define SERIAL_INLINE
  73. #endif
  74.   
  75. #ifdef SERIAL_INLINE
  76. #define _INLINE_ inline
  77. #else
  78. #define _INLINE_
  79. #endif
  80. #define PROBE_RSA (1 << 0)
  81. #define PROBE_ANY (~0)
  82. #define HIGH_BITS_OFFSET ((sizeof(long)-sizeof(int))*8)