1996-04-18 04:25:17 +00:00
|
|
|
.\"
|
|
|
|
.\" Copyright (c) 1994 Andrew McRae. All rights reserved.
|
|
|
|
.\"
|
|
|
|
.\" Redistribution and use in source and binary forms, with or without
|
|
|
|
.\" modification, are permitted provided that the following conditions
|
|
|
|
.\" are met:
|
|
|
|
.\" 1. Redistributions of source code must retain the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer.
|
|
|
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer in the
|
|
|
|
.\" documentation and/or other materials provided with the distribution.
|
|
|
|
.\" 3. The name of the author may not be used to endorse or promote products
|
|
|
|
.\" derived from this software without specific prior written permission.
|
|
|
|
.\"
|
|
|
|
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
|
|
|
.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
|
|
|
.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
|
|
|
.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
|
|
|
|
.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
|
|
|
.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
|
|
.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
|
|
.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
|
|
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
|
|
|
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
1995-08-24 09:03:04 +00:00
|
|
|
.\"
|
1999-08-28 01:35:59 +00:00
|
|
|
.\" $FreeBSD$
|
1999-07-12 20:12:29 +00:00
|
|
|
.\"
|
1996-04-07 09:14:46 +00:00
|
|
|
.Dd November 2, 1994
|
|
|
|
.Dt PCCARD.CONF 5
|
1995-08-24 09:03:04 +00:00
|
|
|
.Os FreeBSD
|
|
|
|
.Sh NAME
|
1996-04-07 09:14:46 +00:00
|
|
|
.Nm pccard.conf
|
1995-08-24 09:03:04 +00:00
|
|
|
.Nd
|
1996-04-07 09:14:46 +00:00
|
|
|
.Xr pccardd 8
|
1995-08-24 09:03:04 +00:00
|
|
|
configuration file
|
|
|
|
.Sh DESCRIPTION
|
|
|
|
The
|
1997-10-06 11:36:08 +00:00
|
|
|
.Nm
|
1995-08-24 09:03:04 +00:00
|
|
|
file is the configuration file for the
|
1996-04-07 09:14:46 +00:00
|
|
|
.Xr pccardd 8
|
1995-08-24 09:03:04 +00:00
|
|
|
PC-CARD slot management daemon.
|
|
|
|
It provides information to allow card
|
|
|
|
identification, and the matching of drivers (along
|
|
|
|
with driver resources) to the PC-CARD cards.
|
|
|
|
.Pp
|
|
|
|
There are four basic elements within the configuration file;
|
|
|
|
An optional
|
|
|
|
.Em "resource pool"
|
|
|
|
preceding the other sections,
|
|
|
|
and one or more
|
|
|
|
.Em "card identifiers" ,
|
|
|
|
and
|
|
|
|
.Em "device instances" .
|
|
|
|
The latter two may appear in any order, and may be
|
|
|
|
interspersed as desired.
|
|
|
|
.Pp
|
2000-03-30 16:01:37 +00:00
|
|
|
The
|
|
|
|
.Pa /etc/pccard.conf
|
|
|
|
file is included from the file
|
|
|
|
.Pa /etc/defaults/pccard.conf ,
|
|
|
|
which contains the default resource pool settings and
|
|
|
|
pccard identifiers database.
|
|
|
|
The user specific configuration can be specified in
|
|
|
|
.Pa /etc/rc.conf
|
|
|
|
when the user wishes to override these defaults and/or
|
|
|
|
add additional entries.
|
|
|
|
.Pp
|
1995-08-24 09:03:04 +00:00
|
|
|
Each PC-CARD card contains configuration tuples that provide
|
|
|
|
the manufacturer and card version; these are used
|
|
|
|
to identify the card specification in the configuration
|
|
|
|
file, and from this find a driver that can be used to
|
2000-03-01 14:09:25 +00:00
|
|
|
interface to the particular card.
|
|
|
|
There is a many-to-one mapping
|
1995-08-24 09:03:04 +00:00
|
|
|
between cards to drivers i.e a single driver may interface to
|
2000-03-01 14:09:25 +00:00
|
|
|
multiple types of cards.
|
|
|
|
To aid this, card parameters may be
|
1997-12-25 09:36:42 +00:00
|
|
|
specified separately from the driver to initialize the card or
|
1996-04-07 09:14:46 +00:00
|
|
|
extract (in the case of a network card) an Ethernet address.
|
1995-08-24 09:03:04 +00:00
|
|
|
.Pp
|
|
|
|
Once a driver is allocated to a card, it stays
|
|
|
|
allocated to that particular card.
|
|
|
|
However, multiple instances of the same type of driver can be
|
|
|
|
configured, so that if two cards are plugged in that map to a
|
|
|
|
similar type of driver, other driver instances of the same name
|
|
|
|
can be configured.
|
|
|
|
.Pp
|
|
|
|
The
|
|
|
|
.Em insert
|
|
|
|
and
|
|
|
|
.Em remove
|
|
|
|
commands allow a shell command line to be executed.
|
|
|
|
The command to be executed is the rest of the line after
|
2000-03-01 14:09:25 +00:00
|
|
|
the keyword.
|
|
|
|
The line can be continued using a backslash.
|
1995-08-24 09:03:04 +00:00
|
|
|
A simple
|
|
|
|
macro substitution allows the current kernel device name
|
|
|
|
.Em ( $device )
|
|
|
|
and
|
1996-04-07 09:14:46 +00:00
|
|
|
network card Ethernet address
|
1995-08-24 09:03:04 +00:00
|
|
|
.Em ( $ether )
|
|
|
|
to be inserted into the command line.
|
1997-02-09 20:39:00 +00:00
|
|
|
.Xr pccardd 8
|
1995-08-24 09:03:04 +00:00
|
|
|
uses the
|
|
|
|
.Xr system 3
|
|
|
|
subroutine to execute the command line.
|
|
|
|
.Pp
|
2000-07-14 19:54:47 +00:00
|
|
|
.Xr pccardd 8
|
|
|
|
will use syslog to annonce the insertion and removal of cards.
|
|
|
|
It uses either the string set by the
|
|
|
|
.Em logstr
|
|
|
|
command, or the manufacturer and card version strings if none has
|
|
|
|
been set.
|
|
|
|
.Pp
|
1995-08-24 09:03:04 +00:00
|
|
|
Numeric values may be expressed as octal, hex or decimal.
|
|
|
|
If a decimal number has
|
|
|
|
.Em k
|
|
|
|
or
|
|
|
|
.Em K
|
|
|
|
appended to it, the value is multiplied by 1024. Names may be
|
|
|
|
quoted using double quotes if spaces are required.
|
|
|
|
A hash character comments out the rest of the line.
|
|
|
|
.Ss "Resource pool"
|
|
|
|
The (optional) section specifies a pool of system resources
|
|
|
|
such as ISA bus memory address space, Input/Output ports and
|
2000-03-01 14:09:25 +00:00
|
|
|
interrupt request numbers.
|
|
|
|
This resource pool is used
|
1995-08-24 09:03:04 +00:00
|
|
|
to allocate address space and interrupt numbers dynamically
|
|
|
|
according to the requirements specified in each driver
|
|
|
|
description.
|
|
|
|
.Pp
|
|
|
|
The syntax of the resources is as follows:
|
|
|
|
.Pp
|
|
|
|
.Dl io Ar start - end ...
|
|
|
|
.Dl memory Ar address size ...
|
|
|
|
.Dl irq Ar irq-number ...
|
|
|
|
.Pp
|
|
|
|
Each of the statements define I/O, memory or IRQ
|
|
|
|
blocks that can be used to allocate to drivers when
|
1997-12-25 09:36:42 +00:00
|
|
|
they are initialized.
|
1995-08-24 09:03:04 +00:00
|
|
|
.Pp
|
1999-08-01 18:04:26 +00:00
|
|
|
The syntax of the debuglevel parameter:
|
|
|
|
.Pp
|
|
|
|
.Dl debuglevel Ar level
|
|
|
|
.Pp
|
1995-08-24 09:03:04 +00:00
|
|
|
Multiple lines of any of the above statements may be
|
|
|
|
present to allow separate blocks of each resource to be
|
|
|
|
defined.
|
|
|
|
.Ss "Card Identifiers"
|
|
|
|
The syntax for card identifiers is:
|
|
|
|
.Pp
|
2000-05-30 15:33:56 +00:00
|
|
|
.Dl card Ar manufacturer version [ add_info1 [ add_info2 ]]
|
1995-08-24 09:03:04 +00:00
|
|
|
.Dl config Ar index driver interrupt [ flags ]
|
|
|
|
.Dl ether Ar offset
|
2000-06-24 05:51:35 +00:00
|
|
|
.Dl reset Ar time
|
|
|
|
.Dl iosize Ar size
|
|
|
|
.Dl memsize Ar size
|
1995-08-24 09:03:04 +00:00
|
|
|
.Dl insert Ar command
|
|
|
|
.Dl remove Ar command
|
2000-07-14 19:54:47 +00:00
|
|
|
.Dl logstr Ar string
|
1995-08-24 09:03:04 +00:00
|
|
|
.Pp
|
|
|
|
The first line is mandatory;
|
|
|
|
the latter statements are optional and can appear in
|
2000-03-01 14:09:25 +00:00
|
|
|
any order.
|
|
|
|
There may be multiple
|
1995-08-24 09:03:04 +00:00
|
|
|
.Em config
|
|
|
|
lines.
|
|
|
|
The
|
|
|
|
.Em card
|
2000-05-30 15:33:56 +00:00
|
|
|
parameters are the Manufacturer name, card version and
|
|
|
|
additional information add_info1, add_info2 that
|
2000-03-01 14:09:25 +00:00
|
|
|
is used to match the values from the card's CIS memory.
|
2000-05-30 15:33:56 +00:00
|
|
|
These parameter can be described in extended regular expression
|
|
|
|
.Xr regex 3
|
|
|
|
if the string is enclosed by '/' like "/.*/".
|
|
|
|
Each of the expressions is evaluated with a character '^' at top.
|
|
|
|
.Pp
|
2000-03-01 14:09:25 +00:00
|
|
|
The
|
1995-08-24 09:03:04 +00:00
|
|
|
.Em config
|
|
|
|
parameters select the particular card's configuration index
|
|
|
|
from the range available in the card's CIS, the driver that
|
|
|
|
is to be associated with this configuration, and the interrupt
|
2000-03-01 14:09:25 +00:00
|
|
|
level (if any) to be assigned.
|
|
|
|
An optional set of flags may
|
1995-08-24 09:03:04 +00:00
|
|
|
be assigned.
|
2000-01-26 17:54:00 +00:00
|
|
|
In
|
|
|
|
.Ar index ,
|
|
|
|
specify either ``auto'' or ``default'' or the range available in the card's CIS.
|
|
|
|
``auto'' allows to allocate resources automatically with information
|
|
|
|
from the CIS and status of using I/O resources.
|
1995-08-24 09:03:04 +00:00
|
|
|
.Pp
|
|
|
|
The optional
|
|
|
|
.Em ether
|
|
|
|
keyword is used when network cards have their physical Ethernet address
|
2000-03-01 14:09:25 +00:00
|
|
|
located within the attribute memory of the card.
|
|
|
|
The parameter of this
|
1995-08-24 09:03:04 +00:00
|
|
|
statement indicates the offset within the attribute memory of the
|
2000-03-01 14:09:25 +00:00
|
|
|
Ethernet address.
|
|
|
|
This value can be used within insert/remove
|
1995-08-24 09:03:04 +00:00
|
|
|
commands using the
|
|
|
|
.Em $ether
|
|
|
|
macro.
|
|
|
|
.Pp
|
2000-06-24 05:51:35 +00:00
|
|
|
The optional
|
|
|
|
.Em reset
|
|
|
|
keyword specifies reset duration at a card insertion in
|
|
|
|
.Ar time
|
|
|
|
milliseconds.
|
|
|
|
Default is 100msec.
|
|
|
|
.Pp
|
|
|
|
.Em iosize
|
|
|
|
and
|
|
|
|
.Em memsize
|
|
|
|
keywords are used with cards whose resources such as I/O ports and
|
|
|
|
shared memory block are not specified in the CIS tuple.
|
|
|
|
.Pp
|
1995-08-24 09:03:04 +00:00
|
|
|
The
|
|
|
|
.Em insert
|
|
|
|
and
|
|
|
|
.Em remove
|
|
|
|
sections allow shell commands to be specified that are executed
|
2000-03-01 14:09:25 +00:00
|
|
|
when the card is inserted or removed.
|
|
|
|
Multiple
|
1995-08-24 09:03:04 +00:00
|
|
|
.Em insert
|
|
|
|
and
|
|
|
|
.Em remove
|
|
|
|
commands are allowed, and they are executed in the order they
|
|
|
|
are listed.
|
2000-07-14 19:54:47 +00:00
|
|
|
.Pp
|
|
|
|
The
|
|
|
|
.Em logstr
|
|
|
|
command allows the user to set the string to be logged when this card is
|
|
|
|
inserted or removed.
|
|
|
|
If
|
|
|
|
.Em logstr
|
|
|
|
isn't specified, then the manufacturer and
|
|
|
|
card version strings from the CIS are used to synthesize the string issued.
|
2000-04-05 18:39:21 +00:00
|
|
|
.Ss "Wildcard entries"
|
|
|
|
Following two wildcard entries of card identifiers are available
|
|
|
|
for generic type of the cards:
|
|
|
|
.Pp
|
|
|
|
.Dl generic serial
|
|
|
|
.Dl generic fixed_disk
|
|
|
|
.Pp
|
|
|
|
The keyword
|
|
|
|
.Em serial
|
|
|
|
matches ``Functional ID: Serial port/modem'' and
|
|
|
|
.Em fixed_disk
|
|
|
|
matches ``Fixed disk card''.
|
|
|
|
The syntax is the same of
|
|
|
|
.Em "card identifiers"
|
|
|
|
but used ``generic'' instead of ``card'' in the first line.
|
|
|
|
These are in the last of
|
|
|
|
.Nm
|
|
|
|
because unmatched cards with the other
|
|
|
|
.Em card
|
|
|
|
entries can match these entries secondly.
|
|
|
|
The alias ``function'' can be used instead of ``generic'' because of
|
|
|
|
the historical reason.
|
|
|
|
.Pp
|
1995-08-24 09:03:04 +00:00
|
|
|
.Sh EXAMPLE
|
|
|
|
A typical configuration file may appear thus:
|
|
|
|
.Bd -literal
|
|
|
|
#
|
|
|
|
# Sample configuration file.
|
|
|
|
#
|
|
|
|
# Pool parameters.
|
|
|
|
#
|
|
|
|
io 0x280 - 0x2F0 0x300 - 0x360
|
|
|
|
irq 5 6 8 9 10 15
|
|
|
|
memory 0xd4000 96k
|
|
|
|
memory 0xc4000 32k
|
|
|
|
#
|
|
|
|
# Card database.
|
|
|
|
#
|
|
|
|
card "RPTI LTD." "EP400" # NE2000 clone
|
|
|
|
ether 0x110
|
|
|
|
config 0x21 "ed0" 5
|
|
|
|
insert ifconfig $device physical $ether
|
|
|
|
insert ifconfig $device bean
|
|
|
|
remove ifconfig $device down
|
|
|
|
|
1997-02-26 15:55:10 +00:00
|
|
|
card "XYZZY" "FAX/1.0"
|
1995-08-24 09:03:04 +00:00
|
|
|
config 0x30 "sio1" 11
|
|
|
|
insert echo start getty
|
|
|
|
remove echo stop getty
|
|
|
|
|
|
|
|
.Ed
|
|
|
|
.Sh FILES
|
2000-03-30 16:01:37 +00:00
|
|
|
.Bl -tag -width /etc/defaults/pccard.conf -compact
|
|
|
|
.It Pa /etc/defaults/pccard.conf
|
1995-08-24 09:03:04 +00:00
|
|
|
The
|
1996-04-07 09:14:46 +00:00
|
|
|
.Xr pccardd 8
|
2000-03-30 16:01:37 +00:00
|
|
|
default configuration file.
|
|
|
|
.It Pa /etc/pccard.conf
|
|
|
|
The
|
|
|
|
user configuration file.
|
1995-08-24 09:03:04 +00:00
|
|
|
.El
|
|
|
|
.Sh SEE ALSO
|
1996-04-07 09:14:46 +00:00
|
|
|
.Xr pccardd 8
|