1*_Functional Specification of SAB8253X ASLX Driver for Linux_* 2 3 4 5 6The SAB8253X serial interface chip is very flexible. It supports most 7of the standard asynchronous serial transmission modes as well as 8synchronous Bit Oriented Protocols (BOPs) and character oriented 9protocols. The Linux ASLX Driver system provides an extremely flexible 10Linux interface to the SAB8253X serial interface chips that are used on 11the Aurora <http://www.auroratech.com/> XX20 adapter cards and 12Multichannel server units whether they are inserted directly into a host 13bus or whether they are connected via a PCI extension system such as the 14Aurora XP7. 15 16 17 18 19 Supported Hardware 20 21 22 23The Linux ASLX Driver supports Aurora SAB8253X communications adapter 24cards and systems for PCI bus systems. Possible adapter card 25configurations are identified as MN20 where M is 1, 2, 4, 8 and N is 0 26or 5. M is the number of ports. N = 0 means that the adapter card does 27not support synchronous modes. N = 5 means the adapter card modes are 28unrestricted. The multichannel server system consists of an host 29adapter card that attaches to an expansion box via the G-Link connection 30cable. The expansion box can host 2000, 2500 and 3500 type Expansion 31Boards (EBs). The 2000 EB provides 15 asynchronous-only RS-232 ports 32and 1 unrestricted RS-232 port. The 2500 EB provides 16 unrestricted 33RS-232 ports. The 3500 EB provides 16 unrestricted serial ports, whose 34physical signaling is under software control. The XP7 is a PCI 35expansion chassis. 36 37 38 39The ASLX correctly identifies the Aurora adapter card or Multichannel 40server and EBs, determines capabilities and provides a software 41interface to configurable capabilities (e.g., a choice of RS-232 [= the 42default], RS 422/423, RS 449, EIA 530, V.35, X.21, RS-485 and none 43[=off] signaling for 3500 EBs). The use of an XP7 should be transparent 44to the driver. The ASLX driver will automatically correct incorrectly 45programmed adapter card or Multichannel server serial EEPROMs. 46Moreover, in addition to the primary serial communications interface, 47the ASLX driver provides a ^�maintenance^� interface to the serial EEPROMs 48so that user intervention can correct an incorrectly programmed EEPROM. 49 50 51 52 53 Serial Communications Interface 54 55 56 57The ASLX driver conforms to the standard Linux driver formalism for TTY 58devices, network devices and character devices. 59 60 61 62The ASLX Linux driver can like all standard Linux drivers either be 63linked into the kernel or be built as a downloadable module that can 64also be cleanly deloaded. 65 66 67 68The ASLX Linux driver functionality provides more than the usual serial 69device driver functionality because it provides the TTY device, network 70device and character device functionality in one package. Moreover, the 71ASLX Linux driver TTY functionality supports asynchronous TTY devices, 72asynchronous CUA devices and synchronous TTY devices. The CUA devices 73can also be used in conjunction with the network device and synchronous 74character device functionalities for the purpose of dynamically setting 75up a dialed link via a modem device. 76 77 78 79The ASLX Linux driver has been developed for Linux on i386 hardware, but 80it has no specific i386 dependence and after recompilation should be 81able to run with Linux that has been compiled for other hardware. 82 83 84 85The driver is structured to minimize Linux 2.4.*-isms. While it has not 86been built as a Linux 2.2.* driver, rebuilding it to work under Linux 872.2.* should not be too difficult. 88 89 90 91 92 Driver Initialization 93 94 95 96Drivers for physical devices usually must provide device detection and 97device initialization. 98 99 100 101The initialization or probe routines of the driver detect all the Aurora 102SAB8253X devices in the system (i.e., these routines look for PCI 103devices that have Aurora device and manufacturer IDs) and carry out any 104necessary low-level PCI initialization of the PLX9050 (XX20 adapter 105cards) or AMCC5920 bridge device (Multichannel server host card). 106 107 108 109The initialization routines of the ASLX driver dynamically allocate all 110structures. The number of Aurora adapter cards in a given system is 111solely limited by the amount of dynamically allocatable kernel memory. 112 113 114 115Note that the performance of a system will be dependent on the number of 116active SAB8253X ports, port modes and speeds, the speed of the CPU, the 117number of CPUs, memory design and similar hardware related considerations. 118 119 120 121This driver currently does not initialize serial adapter cards of 122similar design but with different device or manufacturer IDs, but users 123will be able to access all the functionality described in this document 124for serial ports on SAB8253X based Aurora adapter cards. 125 126 127 128Extending the initialization to the intrinsic SAB8253X ports of SPARC 129hardware or to similar adapter cards of other manufacturers would not be 130difficult. 131 132 133 134Note that the intrinsic SAB8253X ports of the SPARC hardware can serve 135as boot serial consoles because they do not depend on PCI initialization 136as the Aurora adapter cards and multichannel units do. Currently, the 137Aurora ASLX driver does not support boot console or serial console 138functionality, but extending the driver to provide such functionality 139would not be difficult. 140 141 142 143Note further the ASLX driver is designed (viz the Design Specification 144of SAB8253X ASLX Driver for Linux) for hardware that utilizes none of 145the DMA capabilities of SAB8253X extended serial interface controllers. 146Because the ASLX driver transmits data from sk_buffs and receives data 147into sk_buffs extending the driver to support SAB8253X based adapter 148cards that support DMA would not be particularly difficult.. 149 150 151 152In addition, the Zilog 85X30, Intel 8X530 and the AMD 85X30 serial 153communication controllers are character oriented devices that could 154easily be supported within the logic of the ASLX driver. These devices 155do not have the same sort of visible FIFO that the SAB8253X devices 156have, but a FIFO operation looks like a sequence of operations to an 157output or an input register on a device that does not have a visible FIFO. 158 159 160 161 162 The Communications Port 163 164 165 166From the standpoint of the Linux operating system, after initialization, 167the device that the operating system accesses is neither the Aurora 168adapter card or Multichannel server nor the SAB8253X chip but is the 169individual communications port of a SAB8253X chip. Thus a SAB82532 is 170logically two devices, a SAB82538 is logically 8 devices, an Aurora 4520 171logically provides 4 devices, and an Aurora Multichannel server can 172logically provide up to 64 serial communications devices. 173 174 175 176Each communications port according to board capabilities and device 177configuration can provide asynchronous communications or synchronous 178communications as well as access to modem signal status. On a given 179port synchronous communications can either be bit-oriented or 180character-oriented. Currently, the driver only supports bit-oriented 181HDLC flag-framing and bit-stuffing, but the driver source can be easily 182modified to support BSC character-oriented synchronous communications. 183 184 185 186There are two obvious possible ways to extend the driver to support BSC 187communications. Either a configuration flag could be added to indicate 188that the synchronous TTY, network and character devices were running in 189BSC mode and not in BOP mode, or new BSC specific TTY, network and 190character devices could be created. The latter approach would probably 191minimize potential user confusion and errors of connecting BSC ports to 192BOP configured lines and vice-versa. 193 194 195 196/Asynchronous Serial Communications Initialization for a Specific Port/ 197 198 199 200After probing for the hardware, the driver registers the asynchronous 201device dependent routines, whose addresses are values of elements of 202/struct tty_driver/ variables with the device independent TTY driver by 203means of the /tty_register_driver()/ function. 204 205 206 207These functions handle the device dependent aspects of opening a TTY 208port (i.e., completing initialization in asynchronous mode), closing a 209physical TTY port, writing an array of characters to a physical TTY 210port, putting a single character to a physical TTY port, flushing the 211characters in the process of being written to a single TTY port, 212determining how much buffer space is currently available to a single 213physical TTY port, determining how many characters are in the buffer 214space associated with a single physical TTY port, carrying out the 215device dependent aspects of IOCTLs invoked by a user application, 216carrying out flow control at the physical port, carrying out the device 217dependent aspects of setting TERMIOs, handling asynchronous break, and 218waiting for a physical TTY port to transmit all characters associated 219with the port. Other elements of the /struct_tty_driver/ are 220initialized with information used for proc files and other TTY driver 221functionality. 222 223 224 225/Asynchronous Serial Communications Functionality/ 226 227 228 229The driver supports the standard Linux asynchronous TTY and call out 230functionality, which includes all standard STTY and TERMIO IOCTLs, all 231the standard speeds, all the standard flow control formalisms, etc., 232that can be found in the Linux STTY and TERMIO manual pages. 233 234 235 236Note that custom IOCTLs have been added to support the configuration of 237signaling on the WAN multichannel server 3500 cards. 238 239 240 241In addition, customized IOCTLs have been added to support reading and 242programming the serial EEPROM associated with the various Aurora adapter 243cards and units. These are of limited use for users but are helpful in 244debugging cards. Changing the manufacturer or device IDs can render an 245adapter card or unit unusable. 246 247 248 249The asynchronous TTY and call out functionality obey the standard Linux 250block_til_ready logic than enforces arbitration between call out and 251asynchronous TTY access. Current Linux design documents deprecate the 252separate asynchronous call out functionality, but it is not particularly 253obvious how to provide asynchronous call out functionality to set up 254synchronous point-to-point links dynamically without the separate call 255out devices. 256 257 258 259To wit, ckermit does not use the cua devices. The ckermit user sets a 260tty line, turns off carrier watch, executes the connect command, dials 261out and then continues with his terminal session using the same tty 262device on which he dialed out after the modems connect. This procedure 263would not work if the point-to-point connection were to be synchronous 264(or in fact if the point-to-point session were to carry X.25 traffic for 265a PAD session). The cua devices are useful to deal with such /mixed 266mode/ dynamically connected sessions. 267 268 269 270Note that in the past Linux has required that TTY devices be named 271/dev/ttyS* and that call out devices be named /dev/cua*. The devices 272can still be so named, but this naming convention is not obligatory. 273 274 275 276The asynchronous TTY devices use major device 4 and the call out device 277uses major device 5. This assignment is a convention and can be changed 278if necessary. 279 280 281 282Ports are selected by the minor device number. Port minor device 283numbers increase strictly monotonically in accord with the numbering 284convention of the adapter card or adapter unit.[1] <#_ftn1> 285 286 287 288The file /proc/tty/driver/auraserial that is created by the ASLX driver 289helps in mapping port to minor device number. The call out device and 290TTY device of a single port have the same minor device number. To 291calculate the port number of an asynchronous TTY device or of a call out 292device, subtract the minor device number of the first ASLX port from the 293minor device number of the TTY or CUA device of interest. 294 295 296 297/Synchronous Serial TTY Communications Initialization for a Specific Port/ 298 299 300 301After probing for the hardware, the driver registers the synchronous 302device dependent routines, whose addresses are values of elements of 303/struct_tty_driver/ variables with the device independent TTY driver by 304means of the /tty_register_driver()/ function. 305 306 307 308Just as in the case of asynchronous TTYs, these functions handle the 309device dependent aspects of opening a TTY port (i.e., completing 310initialization in synchronous mode), closing a physical TTY port, 311writing an array of characters to a physical TTY port, putting a single 312character to a physical TTY port, flushing the characters in the process 313of being written to a single TTY port, determining how much buffer space 314is currently available to a single physical TTY port, determining how 315many characters are in the buffer space associated with a single 316physical TTY port, carrying out the device dependent aspects of IOCTLs 317invoked by a user application, carrying out flow control at the physical 318port, carrying out the device dependent aspects of setting TERMIOs, and 319waiting for a physical TTY port to transmit all characters associated 320with the port. Other elements of the /struct tty_driver/ are 321initialized with information used for proc files and other TTY driver 322functionality. 323 324 325 326 327 328 Synchronous Serial TTY Communications Functionality 329 330 331 332By default synchronous serial TTY communications takes place on devices 333named /dev/sttyS*, but such names are not required. The major device 334number associated with these ports is dynamically allocated and can be 335found in the /proc/tty/driver/auraserial file. 336 337 338 339Synchronous TTYs act just like asynchronous TTYs (e.g., getty^�s may be 340associated with them, and a user may invoke cu on them) in so far as 341possible (to wit, break processing is not possible on a synchronous TTY). 342 343 344 345As one cannot generally purchase synchronous TTY hardware, synchronous 346TTYs are probably most useful in porting a synchronous TTY application 347from another type of Unix that made use of line disciplines in some 348legacy application. 349 350 351 352Note that the synchronous TTY driver logic obeys the block_til_ready 353arbitration logic so that asynchronous call out devices can be used to 354set up point-to-point synchronous TTY links. 355 356 357 358The synchronous TTY devices support all the standard STTY and TERMIO 359IOCTLs as well as the custom IOCTLs that are described in the previous 360section. Because these IOCTLs do not deal with the issue of synchronous 361clock mode, IOCTLs for setting custom bit rates as well as for 362programming and reading synchronous clock modes are provided. These 363IOCTLs are also accessible through the asynchronous TTY and call out 364devices. Configuring a port to provide clock only affects the port when 365it is used as a synchronous device. 366 367 368 369The minor device number associated with a specific port is the same 370whether it is used as a synchronous TTY, an asynchronous TTY or a call 371out device. To calculate the port number of a synchronous TTY device, 372subtract the minor device number of the first ASLX port from the minor 373device number of the TTY device of interest. 374 375 376 377 378 Synchronous Serial Network Device Initialization 379 380 381 382 383The synchronous network device functionality is to some extent an 384extension of the synchronous TTY functionality. 385 386 387 388After probing for the SAB8253X hardware, the software in addition to 389invoking /tty_register_driver()/ also invokes /register_netdev()/ for 390each SAB8253X port. This registration makes it possible to connect 391SAB8253X ports into the Linux network layer via ifconfig commands like 392the following, which opens the device. 393 394 395 396*ifconfig 8253x001 */{network address or host name}/ 397 398*ifconfig 8253x001* *hw ether* /{MAC address}/ 399 400 401 402Note that by default the number part of the network device name 403corresponds to the serial port number (i.e., the minor device number of 404the associated serial port minus the value of an internal kernel 405variable called sab8253x_minor_start [equal to the minor device number 406of the first TTY device listed in the /proc/tty/driver/auraserial 407file]). The module parameter, sab8253x_minor_start, identifies the 408minor device number at which Aurora asynchronous TTY, synchronous TTY 409and call out devices start. 410 411 412 413The network driver dynamically allocates memory specifically for its use 414as needed on network device open and frees up network device driver 415memory on network device close. 416 417 418 419 420 Synchronous Serial Network Devices 421 422 423 424The network devices like all standard Linux network devices are not 425visible in the /dev directory. 426 427 428 429If an 8 port adapter card is installed in a Linux system that has an 430Ethernet port, the new SAB8253X Linux driver makes it possible to use 431the system as an 8 WAN x 1 LAN port router. 432 433 434 435The SAB8253X network device functionality emulates an Ethernet device. 436The network device functionality requires the implementation of the 437following functions. As a consequence, the network portion of the ASLX 438driver implements the standard Ethernet functionality as far as 439possible. In addition, the network driver requires a special IOCTL to 440set a pseudomac address. 441 442 443 444In addition, the network driver needs some functionality that goes 445beyond the standard Ethernet functionality, for it must be possible 446dynamically to establish or reestablish synchronous links by means of 447the asynchronous call out device logic. 448 449 450 451Using the call out device logic in conjunction with the network device 452requires an extension of the call out device arbitration logic. 453 454 455 456The standard call out device arbitration logic requires that the call 457out device start first and be invoked from the same process or process 458group that opens the TTY device while the TTY device blocks until the 459call out succeeds. Such logic is inapplicable to the network device. 460The call out device must be opened while the corresponding network 461device is open. The corresponding network device never blocks but 462informs the network layer of outgoing network congestion. 463 464 465 466 467 468 469 Synchronous Serial Character Device Initialization 470 471 472 473 474The synchronous character device functionality is to some extent an 475extension of the synchronous network functionality. 476 477 478 479After probing for the SAB8253X hardware, the software besides invoking 480/tty_register_driver()/ also invokes /register_chardev()/ in addition to 481/register_netdev()/ for each SAB8253X port. This registration makes it 482possible to access SAB8253X port packet functionality independently of 483the Linux network layer via function calls associated with a standard 484character device. 485 486 487 488The major device number of the synchronous serial character device can 489be found in the /proc/devices file. Note that by default the minor 490device number of each synchronous serial character device file (e.g., 491/dev/sab8253xC* if mknod is invoked as below) corresponds to the minor 492device number of the associated serial port minus the value of an 493internal kernel variable/module parameter called sab8253x_minor_start 494(equal to the minor device number of the first TTY device indentified in 495the /proc/tty/driver/auraserial file). The variable 496sab8253x_minor_start identifies the minor device number at which Aurora 497asynchronous TTY, synchronous TTY and call out devices start. 498 499 500 501*mknod /dev/sab8253xC*{number} *c* {major dev number} {minor dev number} 502 503 504 505The character driver dynamically allocates memory specifically for its 506use as needed on network device open and frees up network device driver 507memory on network device close. 508 509 510 511/Synchronous Serial Character Device/ 512 513/ 514/ 515 516/ / 517 518 519 520The SAB8253X synchronous character device functionality implements 521essentially the same functions as the SAB8253X synchronous network 522device functionality with the addition of a read/receive function that 523will pass received data packets to a user application and with the 524addition of an fasync helper function if the driver is to support 525asynchronous notification to the user application. This functionality 526is provided so that users that wish to implement their own bit oriented 527synchronous protocols may directly access the serial data stream without 528having to work around the TTY driver or the Linux network layer. 529 530 531 532Note that while the network device is only opened once by the Linux 533network layer, the character device may be opened multiple times by a 534process or defined process group just like the TTY driver. 535 536 537 538In a sense, the synchronous character device implements an emulation of 539Solaris putmsg/getmsg functionality for Aurora^�s synchronous serial 540device. The availability of such emulation should help the portation of 541applications from Solaris to a Linux platform that uses Aurora hardware 542and software. 543 544 545 546The asynchronous functionality is useful for those protocols like LAPB, 547which do not work well if the physical driver buffers up low priority 548packets while other packets are being transmitted. The asynchronous 549notification can provide notification that there are no packets of any 550sort in the process of being transmitted and that there are no high 551priority packets buffered within the driver. On receiving this 552notification, the user application could transmit the next low priority 553packet. 554 555 556 557Note that the synchronous serial character device interacts with the 558call out device almost exactly like the TTY devices. 559 560 561 562In the interest of keeping the interfaces simple and not introducing 563extra foci for bugs, there are no IOCTLs implemented for this device. 564If it is necessary to set a clocking mode or baud rate etc., the IOCTL 565call is made via the STTY, TERMIO or extended IOCTLs associated with the 566TTY driver functionalities. 567 568 569 570 571 Common Interrupt Handling Functionality 572 573 574 575All the above functionality shares a common interrupt handler that 576invokes indirectly functionality-specific receive_chars, transmit_chars 577and check_status functions to receive character data, to transmit 578character data and to check signal status. 579 580 581 582In other words, the interrupt handler must support all possible 583functionalities simultaneously on a group of ports associated with a 584single interrupt simultaneously. 585 586 587 588Linux is not capable of registering an interrupt handler for each port 589separately (when there are many ports ^� the specialty of Aurora 590hardware), and such an approach would have lower performance than having 591a single interrupt handler that polled the ports. In any case, 592interrupt status registers associated with the Aurora hardware often 593indicate interrupt status on several ports simultaneous. It is 594preferable to read such registers once especially with the Multichannel 595server hardware. 596 597 598 599 600 Proc Files 601 602 603 604The following traces show how the driver interacts with (or creates) 605various /proc status files. 606 607 608 609 610martillo@ylith:~ > cat /proc/tty/driver/auraserial 611 612serinfo:2.01N driver:1.22 613 614TTY MAJOR = 4, CUA MAJOR = 5, STTY MAJOR = 254. 615 616128: port 0: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: close: 617NOPRG 618 619129: port 1: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: openA: 620NOPRG 621 622130: port 2: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: openA: 623NOPRG 624 625131: port 3: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: close: 626NOPRG 627 628132: port 4: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: close: 629NOPRG 630 631133: port 5: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: openS: 632NOPRG 633 634134: port 6: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: close: 635NOPRG 636 637135: port 7: sab82538: v3: chip 0: ATI 8520P: bus 2: slot 10: NR: close: 638NOPRG 639 640136: port 0: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: openA: 641RS232 642 643137: port 1: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: openA: 644RS232 645 646138: port 2: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: openA: 647RS232 648 649139: port 3: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: close: 650RS232 651 652140: port 4: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: close: 653RS232 654 655141: port 5: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: close: 656RS232 657 658142: port 6: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: close: 659RS232 660 661143: port 7: sab82538: v2: chip 0: ATI WANMS: bus 2: slot 11: NR: close: 662RS232 663 664144: port 0: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: openA: 665RS232 666 667145: port 1: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: close: 668RS232 669 670146: port 2: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: close: 671RS232 672 673147: port 3: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: close: 674RS232 675 676148: port 4: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: close: 677RS530 678 679149: port 5: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: close: 680RS232 681 682150: port 6: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: close: 683RS232 684 685151: port 7: sab82538: v2: chip 1: ATI WANMS: bus 2: slot 11: NR: openA: 686RS232 687 688152: port 0: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: openA: 689RS232 690 691153: port 1: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: close: 692RS232 693 694154: port 2: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: close: 695RS232 696 697155: port 3: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: close: 698RS232 699 700156: port 4: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: close: 701RS232 702 703157: port 5: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: close: 704RS232 705 706158: port 6: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: close: 707RS232 708 709159: port 7: sab82538: v2: chip 2: ATI WANMS: bus 2: slot 11: NR: openA: 710RS232 711 712160: port 0: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 713RS232 714 715161: port 1: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 716RS232 717 718162: port 2: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 719RS232 720 721163: port 3: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 722RS232 723 724164: port 4: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 725RS232 726 727165: port 5: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 728RS232 729 730166: port 6: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 731RS232 732 733167: port 7: sab82538: v2: chip 3: ATI WANMS: bus 2: slot 11: NR: close: 734RS232 735 736168: port 0: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: openA: 737RS232 738 739169: port 1: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 740RS232 741 742170: port 2: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 743RS232 744 745171: port 3: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 746RS232 747 748172: port 4: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 749RS232 750 751173: port 5: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 752RS232 753 754174: port 6: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 755RS232 756 757175: port 7: sab82538: v2: chip 4: ATI WANMS: bus 2: slot 11: NR: close: 758RS232 759 760176: port 0: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 761RS232 762 763177: port 1: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 764RS232 765 766178: port 2: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 767RS232 768 769179: port 3: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 770RS232 771 772180: port 4: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 773RS232 774 775181: port 5: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 776RS232 777 778182: port 6: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 779RS232 780 781183: port 7: sab82538: v2: chip 5: ATI WANMS: bus 2: slot 11: NR: close: 782RS232 783 784184: port 0: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: openA: 785RS232 786 787185: port 1: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 788RS232 789 790186: port 2: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 791RS232 792 793187: port 3: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 794RS232 795 796188: port 4: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 797RS232 798 799189: port 5: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 800RS232 801 802190: port 6: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 803RS232 804 805191: port 7: sab82538: v2: chip 6: ATI WANMS: bus 2: slot 11: NR: close: 806RS232 807 808192: port 0: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 809RS232 810 811193: port 1: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 812RS232 813 814194: port 2: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 815RS232 816 817195: port 3: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 818RS232 819 820196: port 4: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 821RS232 822 823197: port 5: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 824RS232 825 826198: port 6: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: close: 827RS232 828 829199: port 7: sab82538: v2: chip 7: ATI WANMS: bus 2: slot 11: NR: openA: 830RS232 831 832 833 834The above file indicates the minor device number, port number relative 835to chip, chip type, chip version number, chip number (meaningful for 8364X20 and multichannel servers), interface type, bus number, slot number, 837port availability (AO = asynchronous only, NR = No Restrictions, or NA = 838Not Available), status (closed, open Synchronous, open Asynchronous, 839open Character, or open Network), and signaling type (NOPRG = not 840selectable programmatically; other possibilities inclue OFF, RS232, 841RS442, RS449, RS530 and V.35). 842 843 844 845 846martillo@ylith:/proc > cat /proc/pci 847 848PCI devices found: 849 850 Bus 0, device 0, function 0: 851 852 Host bridge: Intel Corporation 82820 820 (Camino) Chipset Host 853Bridge (MCH) (rev 4). 854 855 Prefetchable 32 bit memory at 0xf8000000 [0xfbffffff]. 856 857 Bus 0, device 1, function 0: 858 859 PCI bridge: Intel Corporation 82820 820 (Camino) Chipset PCI to AGP 860Bridge (rev 4). 861 862 Master Capable. Latency=64. Min Gnt=8. 863 864 Bus 0, device 30, function 0: 865 866 PCI bridge: Intel Corporation 82801AA PCI Bridge (rev 2). 867 868 Master Capable. No bursts. Min Gnt=2. 869 870 Bus 0, device 31, function 0: 871 872 ISA bridge: Intel Corporation 82801AA ISA Bridge (LPC) (rev 2). 873 874 Bus 0, device 31, function 1: 875 876 IDE interface: Intel Corporation 82801AA IDE (rev 2). 877 878 I/O at 0xffa0 [0xffaf]. 879 880 Bus 0, device 31, function 2: 881 882 USB Controller: Intel Corporation 82801AA USB (rev 2). 883 884 IRQ 10. 885 886 I/O at 0xef80 [0xef9f]. 887 888 Bus 0, device 31, function 3: 889 890 SMBus: Intel Corporation 82801AA SMBus (rev 2). 891 892 IRQ 9. 893 894 I/O at 0xefa0 [0xefaf]. 895 896 Bus 1, device 0, function 0: 897 898 VGA compatible controller: nVidia Corporation NV15 (Geforce2 GTS) 899(rev 164). 900 901 IRQ 11. 902 903 Master Capable. Latency=64. Min Gnt=5.Max Lat=1. 904 905 Non-prefetchable 32 bit memory at 0xfd000000 [0xfdffffff]. 906 907 Prefetchable 32 bit memory at 0xe8000000 [0xefffffff]. 908 909 Bus 2, device 8, function 0: 910 911 Ethernet controller: 3Com Corporation 3c905C-TX [Fast Etherlink] 912(rev 120). 913 914 IRQ 11. 915 916 Master Capable. Latency=64. Min Gnt=10.Max Lat=10. 917 918 I/O at 0xdc00 [0xdc7f]. 919 920 Non-prefetchable 32 bit memory at 0xfeacfc00 [0xfeacfc7f]. 921 922 Bus 2, device 9, function 0: 923 924 Unknown mass storage controller: Promise Technology, Inc. 20267 (rev 2). 925 926 IRQ 9. 927 928 Master Capable. Latency=64. 929 930 I/O at 0xdff0 [0xdff7]. 931 932 I/O at 0xdfe4 [0xdfe7]. 933 934 I/O at 0xdfa8 [0xdfaf]. 935 936 I/O at 0xdfe0 [0xdfe3]. 937 938 I/O at 0xdf00 [0xdf3f]. 939 940 Non-prefetchable 32 bit memory at 0xfeae0000 [0xfeafffff]. 941 942 Bus 2, device 10, function 0: 943 944 Communication controller: PCI device 125c:0101 (Aurora Technologies, 945Inc.) (rev 1). 946 947 IRQ 3. 948 949 Non-prefetchable 32 bit memory at 0xfeacf800 [0xfeacf87f]. 950 951 Non-prefetchable 32 bit memory at 0xfeacf400 [0xfeacf5ff]. 952 953 Non-prefetchable 32 bit memory at 0xfeacf000 [0xfeacf1ff]. 954 955 Bus 2, device 11, function 0: 956 957 Communication controller: PCI device 125c:0101 (Aurora Technologies, 958Inc.) (rev 1). 959 960 IRQ 10. 961 962 Non-prefetchable 32 bit memory at 0xfeacec00 [0xfeacec7f]. 963 964 Non-prefetchable 32 bit memory at 0xfeace000 [0xfeace7ff]. 965 966 Non-prefetchable 32 bit memory at 0xfeacd800 [0xfeacdfff]. 967 968 969 970The above file indications PCI resources that the Aurora adapter card or 971unit uses. 972 973 974 975 976martillo@ylith:/proc > cat /proc/devices 977 978Character devices: 979 980 1 mem 981 982 2 pty 983 984 3 ttyp 985 986 4 ttyS 987 988 5 cua 989 990 7 vcs 991 992 10 misc 993 994 14 sound 995 996128 ptm 997 998136 pts 999 1000162 raw 1001 1002180 usb 1003 1004253 sab8253xc 1005 1006254 sttyS 1007 1008 1009 1010Block devices: 1011 1012 2 fd 1013 1014 22 ide1 1015 1016 33 ide2 1017 1018 1019 1020The above file provides the major device number associated with the 1021synchronous serial character device. 1022 1023 1024 1025martillo@ylith:/proc > cat /proc/modules 1026 1027ASLX 84336 5 (autoclean) 1028 1029 1030 1031The above file indicates that the ASLX module has been dynamically 1032linked into the kernel. If the ASLX is statically linked into the 1033kernel, it will not appear in this file. 1034 1035 1036 1037martillo@ylith:/proc > cat /proc/interrupts 1038 1039 CPU0 1040 1041 0: 25311 XT-PIC timer 1042 1043 1: 401 XT-PIC keyboard 1044 1045 2: 0 XT-PIC cascade 1046 1047 3: 22 XT-PIC sab8253x 1048 1049 9: 20055 XT-PIC ide2 1050 1051 10: 27 XT-PIC usb-uhci, sab8253x 1052 1053 11: 38 XT-PIC eth0 1054 1055 12: 2720 XT-PIC PS/2 Mouse 1056 1057 15: 7 XT-PIC ide1 1058 1059NMI: 0 1060 1061LOC: 0 1062 1063ERR: 0 1064 1065MIS: 0 1066 1067 1068 1069The above file indicates the interrupts that are being used by Aurora 1070adapter cards. 1071 1072 1073martillo@ylith:/proc/net > cat /proc/net/dev 1074 1075Inter-| Receive | Transmit 1076 1077 face |bytes packets errs drop fifo frame compressed 1078multicast|bytes packets errs drop fifo colls carrier compressed 1079 1080 lo: 1080 16 0 0 0 0 0 0 10811080 16 0 0 0 0 0 0 1082 1083 eth0: 2316 19 0 0 0 0 0 0 1084 1836 19 0 0 0 1 0 0 1085 10868253x000: 0 0 0 0 0 0 0 10870 0 0 0 0 0 0 0 0 1088 10898253x001: 0 0 0 0 0 0 0 10900 0 0 0 0 0 0 0 0 1091 10928253x002: 0 0 0 0 0 0 0 10930 0 0 0 0 0 0 0 0 1094 10958253x003: 0 0 0 0 0 0 0 10960 0 0 0 0 0 0 0 0 1097 10988253x004: 0 0 0 0 0 0 0 10990 0 0 0 0 0 0 0 0 1100 11018253x005: 0 0 0 0 0 0 0 11020 0 0 0 0 0 0 0 0 1103 11048253x006: 0 0 0 0 0 0 0 11050 0 0 0 0 0 0 0 0 1106 11078253x007: 0 0 0 0 0 0 0 11080 0 0 0 0 0 0 0 0 1109 11108253x008: 0 0 0 0 0 0 0 11110 0 0 0 0 0 0 0 0 1112 11138253x009: 0 0 0 0 0 0 0 11140 0 0 0 0 0 0 0 0 1115 11168253x010: 0 0 0 0 0 0 0 11170 0 0 0 0 0 0 0 0 1118 11198253x011: 0 0 0 0 0 0 0 11200 0 0 0 0 0 0 0 0 1121 1122 1123 1124The above file provides statistics on ASLX network interfaces. 1125 1126 1127 1128martillo@ylith:/proc > cat /proc/iomem 1129 113000000000-0009fbff : System RAM 1131 11320009fc00-0009ffff : reserved 1133 1134000a0000-000bffff : Video RAM area 1135 1136000c0000-000c7fff : Video ROM 1137 1138000cc000-000cdfff : Extension ROM 1139 1140000ce000-000ce7ff : Extension ROM 1141 1142000f0000-000fffff : System ROM 1143 114400100000-0ffbffff : System RAM 1145 1146 00100000-00260dfe : Kernel code 1147 1148 00260dff-002f325f : Kernel data 1149 11500ffc0000-0fff7fff : ACPI Tables 1151 11520fff8000-0fffffff : ACPI Non-volatile Storage 1153 1154e4600000-f46fffff : PCI Bus #01 1155 1156 e8000000-efffffff : nVidia Corporation NV15 (Geforce2 GTS) 1157 1158f4700000-f47fffff : PCI Bus #02 1159 1160f8000000-fbffffff : Intel Corporation 82820 820 (Camino) Chipset Host 1161Bridge (MCH) 1162 1163fc900000-fe9fffff : PCI Bus #01 1164 1165 fd000000-fdffffff : nVidia Corporation NV15 (Geforce2 GTS) 1166 1167fea00000-feafffff : PCI Bus #02 1168 1169 feacd800-feacdfff : PCI device 125c:0101 (Aurora Technologies, Inc.) 1170 1171 feace000-feace7ff : PCI device 125c:0101 (Aurora Technologies, Inc.) 1172 1173 feacec00-feacec7f : PCI device 125c:0101 (Aurora Technologies, Inc.) 1174 1175 feacf000-feacf1ff : PCI device 125c:0101 (Aurora Technologies, Inc.) 1176 1177 feacf400-feacf5ff : PCI device 125c:0101 (Aurora Technologies, Inc.) 1178 1179 feacf800-feacf87f : PCI device 125c:0101 (Aurora Technologies, Inc.) 1180 1181 feacfc00-feacfc7f : 3Com Corporation 3c905C-TX [Fast Etherlink] 1182 1183 feae0000-feafffff : Promise Technology, Inc. 20267 1184 1185ffb80000-ffbfffff : reserved 1186 1187fff00000-ffffffff : reserved 1188 1189 1190 1191The above file indicate the I/O memory mapping of the Aurora devices. 1192 1193 1194 1195 1196 ASLX IOCTL Summary 1197 1198 1199 1200The ASLX driver supports the standard TTY and Ethernet driver IOCTLs. 1201In addition, the following TTY driver IOCTLs are supported (on 1202asynchronous/synchronous TTY devices and on asynchronous CUA devices): 1203 1204 1205 1206/1. /set custom baud rate,// 1207 1208/2. /get baud rate,// 1209 1210/3. /read EEPROM,// 1211 1212/4. /set EEPROM,// 1213 1214/5. /get clocking mode,// 1215 1216/6. /set clocking mode// 1217 1218/7. /get WAN MCS signaling configuration,// 1219 1220/8. /set WAN MCS signaling configuration,// 1221 1222/9. /clear network driver statistics.// 1223 1224 1225 1226In addition, the ASLX driver supports a network IOCTL to clear interface 1227statistics. 1228 1229 1230 1231/Source Code Functionality/ 1232 1233 1234 1235To facilitate user modification and extension of the ASLX driver, the 1236code has been written as clearly as possible, and the various 1237functionalities (asynchronous TTY, synchronous TTY, network device and 1238character devices, initialization, interrupt, bridge initialization, 1239etc) have their own files to discourage massive unsupportable changes to 1240driver logic. 1241 1242 1243 1244/Summary/ 1245 1246 1247 1248The driver attempts to provide as much as possible of the functionality 1249of the SAB8253X communication controller and the Aurora hardware in a 1250form that is both useful and friendly to the Linux user with as much 1251self-configuration as possible and by means of the standard Linux 1252interfaces. The custom portion of the interface has been minimized as 1253much as possible, and duplication of this interface across the TTY, 1254network, and synchronous serial character interface has been eschewed. 1255 1256 1257 1258In this version of the driver for each type of custom configuration, 1259there is only one IOCTL, and this custom configuration is shared among 1260all the functionalities that share a given physical port. 1261 1262 1263 1264In most applications of this driver, the user will generally not have to 1265use any of the custom IOCTLs unless he is using a serial port as a 1266synchronous device that is providing clock, in which case he would have 1267to use an IOCTL to make the port provide clock and he might have to use 1268another IOCTL to set a custom baud rate. In all cases, if the network 1269driver is used on a given port, that port would have to be assigned a 1270pseudomac address by means of the standard ifconfig command. 1271 1272 1273 1274Altogether the driver provides the functionality needed for massive 1275asynchronous and synchronous TTY connectivity, for shake-and-bake WAN 1276networking and for synchronous legacy interconnect by means of a custom 1277application. Linux systems that host Aurora communications cards that 1278interface to the OS via the ASLX driver can replace a massive 1279point-of-sales servers, expensive WAN networking systems or custom 1280synchronous legacy protocol-to-standard protocol interconnect hardware. 1281 1282 1283 1284 1285------------------------------------------------------------------------ 1286 1287[1] <#_ftnref1> In the ASLX driver internal device lists, adapter cards 1288and adapter units are ordered in reverse order to the ordering on the 1289kernel PCI device list by type. Multiport adapter cards are ordered 1290last. Compact multiport adapter cards are ordered next. And 1291Multichannel units are ordered next, i.e., first. The ordering of 1292adapter cards and interface chips on internal driver lists currently 1293does not affect external functionality with one possible exception. 1294Adapter cards are also listed on per type per interrupt lists. If 1295there are many cards associated with a given interrupt, it is possible 1296that list order might cause maximum delay in loading and emptying port 1297FIFOs to be exceeded. As every card on the interrupt list must be 1298interrogated when an interrupt is received, avoiding the problem might 1299require moving to a faster processor based system. Multi-CPU hardware 1300would not help. 1301 1302 1303 1304