summaryrefslogtreecommitdiff
path: root/package/libertas/src/README
diff options
context:
space:
mode:
Diffstat (limited to 'package/libertas/src/README')
-rw-r--r--package/libertas/src/README417
1 files changed, 417 insertions, 0 deletions
diff --git a/package/libertas/src/README b/package/libertas/src/README
index d860fc3..2706a42 100644
--- a/package/libertas/src/README
+++ b/package/libertas/src/README
@@ -28,6 +28,423 @@ DRIVER LOADING
insmod usb8388.ko [fw_name=usb8388.bin]
+=====================
+IWPRIV COMMAND
+=====================
+
+NAME
+ This manual describes the usage of private commands used in Marvell WLAN
+ Linux Driver. All the commands available in Wlanconfig will not be available
+ in the iwpriv.
+
+SYNOPSIS
+ iwpriv <ethX> <command> [sub-command] ...
+
+ iwpriv ethX setregioncode <n>
+ iwpriv ethX getregioncode
+
+Version 5 Command:
+ iwpriv ethX ledgpio <n>
+
+BT Commands:
+ The blinding table (BT) contains a list of mac addresses that will be,
+ by default, ignored by the firmware. It is also possible to invert this
+ behavior so that we will ignore all traffic except for the portion
+ coming from mac addresess in the list. It is primarily used for
+ debugging and testing networks. It can be edited and inspected with
+ the following commands:
+
+ iwpriv ethX bt_reset
+ iwpriv ethX bt_add <mac_address>
+ iwpriv ethX bt_del <mac_address>
+ iwpriv ethX bt_list <id>
+ iwpriv ethX bt_get_invert <n>
+ iwpriv ethX bt_set_invert <n>
+
+FWT Commands:
+ The forwarding table (FWT) is a feature used to manage mesh network
+ routing in the firmware. The FWT is essentially a routing table that
+ associates a destination mac address (da) with a next hop receiver
+ address (ra). The FWT can be inspected and edited with the following
+ iwpriv commands, which are described in greater detail below.
+ Eventually, the table will be automatically maintained by a custom
+ routing protocol.
+
+ NOTE: FWT commands replace the previous DFT commands. What were the DFT
+ commands?, you might ask. They were an earlier API to the firmware that
+ implemented a simple MAC-layer forwarding mechanism. In the unlikely
+ event that you were using these commands, you must migrate to the new
+ FWT commands which can be used to achieve the same functionality.
+
+ iwpriv ethX fwt_add [parameters]
+ iwpriv ethX fwt_del [parameters]
+ iwpriv ethX fwt_lookup [parameters]
+ iwpriv ethX fwt_list [parameters]
+ iwpriv ethX fwt_list_route [parameters]
+ iwpriv ethX fwt_list_neigh [parameters]
+ iwpriv ethX fwt_reset [parameters]
+ iwpriv ethX fwt_cleanup
+ iwpriv ethX fwt_time
+
+MESH Commands:
+
+ The MESH commands are used to configure various features of the mesh
+ routing protocol. The following commands are supported:
+
+ iwpriv ethX mesh_get_ttl
+ iwpriv ethX mesh_set_ttl ttl
+ iwpriv ethX mesh_get_bcastr rate
+ iwpriv ethX mesh_set_bcastr rate
+ iwpriv ethX get_rreq_delay
+ iwpriv ethX set_rreq_delay delay
+ iwpriv ethX get_route_exp
+ iwpriv ethX set_route_exp time
+ iwpriv ethX get_link_costs
+ iwpriv ethX set_link_costs "cost54 cost36 cost11 cost1"
+
+DESCRIPTION
+ Those commands are used to send additional commands to the Marvell WLAN
+ card via the Linux device driver.
+
+ The ethX parameter specifies the network device that is to be used to
+ perform this command on. it could be eth0, eth1 etc.
+
+setregioncode
+ This command is used to set the region code in the station.
+ where value is 'region code' for various regions like
+ USA FCC, Canada IC, Spain, France, Europe ETSI, Japan ...
+
+ Usage:
+ iwpriv ethX setregioncode 0x10: set region code to USA (0x10).
+
+getregioncode
+ This command is used to get the region code information set in the
+ station.
+
+ledgpio
+ This command is used to set/get LEDs.
+
+ iwpriv ethX ledgpio <LEDs>
+ will set the corresponding LED for the GPIO Line.
+
+ iwpriv ethX ledgpio
+ will give u which LEDs are Enabled.
+
+ Usage:
+ iwpriv eth1 ledgpio 1 0 2 1 3 4
+ will enable
+ LED 1 -> GPIO 0
+ LED 2 -> GPIO 1
+ LED 3 -> GPIO 4
+
+ iwpriv eth1 ledgpio
+ shows LED information in the format as mentioned above.
+
+ Note: LED0 is invalid
+ Note: Maximum Number of LEDs are 16.
+
+bcn_control
+ This command is used to enable disable beacons. This can also be used
+ to set beacon interval.
+
+ Usage:
+ iwpriv ethX bcn_control [enable] [beacon_interval]
+
+ enable: 0 to disable beacon. 1 to enable beacon.
+ beacon_interval: 20 - 1000ms.
+
+ Examples:
+ 1. iwpriv ethX bcn_control
+ Returns (x, y), where x if 1, indicates beacon is enabled, y
+ beacon period.
+ 2. iwpriv ethX bcn_control 0
+ Turns off beacon transmission.
+ 3. iwpriv ethX bcn_control 1 500
+ Enable beacon with beacon interval 500ms.
+
+
+ledbhv
+ Command iwpriv mshX ledbhv can be used to change default LEDs behaviors.
+ A given LED behavior can be on, off or blinking. The duty/cycle can be set
+ when behavior is programmed as blinking.
+
+ Usage:
+
+ 1. To get default LED behavior
+ iwpriv mshX ledbhv <firmware state>
+
+ 2. To set or change default LED behavior
+ iwpriv mshX ledbhv <firmware state> <lednum> <behavior> <arg>
+
+ firmware state: The following are some of the relevant states.
+ 00: disconnected
+ 01: firmware is scanning
+ 02: firmware is connected and awake
+ 03: firmware is sleeping
+ 04: connected deep sleep
+ 06: firmware disconnected link lost
+ 07: firmware disconnected disassociated
+ 09: data transfer while firmware is associated and not scanning.
+ If firmware is already in this state, LED behavior does not change
+ on this data transfer.
+ 10: firmware idle, not scanning, not disconnected or disassociated.
+
+ lednum: 1 or 2 for first and second LED.
+
+ behavior: 0 for steady ON, 1 - steady off and 2- blinking.
+
+ arg: It is used when behavior is 2 to set duty and cycle. It is defined as
+ (duty << 4 | cycle). Here duty could be 0..4 and cycle 0..5 for 34,
+ 74, 149, 298, 596, 1192 ms respectively.
+
+ Examples:
+
+ 1. To get default behavior for scan
+ iwpriv mshX ledbhv 1
+
+ 2. To get default behavior while data transfer
+ iwpriv mshX ledbhv 9
+
+ 3. To turn off LED 2
+ iwpriv mshX ledbhv 2 2 1 0
+ iwpriv mshX ledbhv 10 2 1 0
+
+ 4. To enable LED 2 and blink LED 1 while data transfer.
+ iwpriv mshX ledbhv 9 2 0 0
+ iwpriv mshX ledbhv 9 1 2 4
+
+ 5. To change duty cycle of LED 2 during data transfer
+ iwpriv mshX ledbhv 9 2 2 36
+
+ 6. To turn ON LED 2 when firmware is disassociated/disconnected.
+ iwpriv mshX ledbhv 0 2 0 0
+
+
+fwt_add
+ This command is used to insert an entry into the FWT table. The list of
+ parameters must follow the following structure:
+
+ iwpriv ethX fwt_add da ra [metric dir rate ssn dsn hopcount ttl expiration sleepmode snr]
+
+ The parameters between brackets are optional, but they must appear in
+ the order specified. For example, if you want to specify the metric,
+ you must also specify the dir, ssn, and dsn but you need not specify the
+ hopcount, expiration, sleepmode, or snr. Any unspecified parameters
+ will be assigned the defaults specified below.
+
+ The different parameters are:-
+ da -- DA MAC address in the form 00:11:22:33:44:55
+ ra -- RA MAC address in the form 00:11:22:33:44:55
+ metric -- route metric (cost: smaller-metric routes are
+ preferred, default is 0)
+ dir -- direction (1 for direct, 0 for reverse,
+ default is 1)
+ rate -- data rate used for transmission to the RA,
+ as specified for the rateadapt command,
+ default is 3 (11Mbps)
+ ssn -- Source Sequence Number (time at the RA for
+ reverse routes. Default is 0)
+ dsn -- Destination Sequence Number (time at the DA
+ for direct routes. Default is 0)
+ hopcount -- hop count (currently unused, default is 0)
+ ttl -- TTL (Only used in reverse entries)
+ expiration -- entry expiration (in ticks, where a tick is
+ 1024us, or ~ 1ms. Use 0 for an indefinite
+ entry, default is 0)
+ sleepmode -- RA's sleep mode (currently unused, default is
+ 0)
+ snr -- SNR in the link to RA (currently unused,
+ default is 0)
+
+ The command does not return anything.
+
+fwt_del
+ This command is used to remove an entry to the FWT table. The list of
+ parameters must follow the following structure:
+
+ iwpriv ethX fwt_del da ra [dir]
+
+ where the different parameters are:-
+ da -- DA MAC address (in the form "00:11:22:33:44:55")
+ ra -- RA MAC address (in the form "00:11:22:33:44:55")
+ dir -- direction (1 for direct, 0 for reverse,
+ default is 1)
+
+ The command does not return anything.
+
+fwt_lookup
+ This command is used to get the best route in the FWT table to a given
+ host. The only parameter is the MAC address of the host that is being
+ looked for.
+
+ iwpriv ethX fwt_lookup da
+
+ where:-
+ da -- DA MAC address (in the form "00:11:22:33:44:55")
+
+ The command returns an output string identical to the one returned by
+ fwt_list described below.
+
+
+fwt_list
+ This command is used to list a route from the FWT table. The only
+ parameter is the index into the table. If you want to list all the
+ routes in a table, start with index=0, and keep listing until you get a
+ "(null)" string. Note that the indicies may change as the fwt is
+ updated. It is expected that most users will not use fwt_list directly,
+ but that a utility similar to the traditional route command will be used
+ to invoke fwt_list over and over.
+
+ iwpriv ethX fwt_list index
+
+ The output is a string of the following form:
+
+ da ra valid metric dir rate ssn dsn hopcount ttl expiration
+ sleepmode snr precursor
+
+ where the different fields are:-
+ da -- DA MAC address (in the form "00:11:22:33:44:55")
+ ra -- RA MAC address (in the form "00:11:22:33:44:55")
+ valid -- whether the route is valid (0 if not valid)
+ metric -- route metric (cost: smaller-metric routes are preferred)
+ dir -- direction (1 for direct, 0 for reverse)
+ rate -- data rate used for transmission to the RA,
+ as specified for the rateadapt command
+ ssn -- Source Sequence Number (time at the RA for reverse routes)
+ dsn -- Destination Sequence Number (time at the DA for direct routes)
+ hopcount -- hop count (currently unused)
+ ttl -- TTL (only used in reverse entries)
+ expiration -- entry expiration (in ticks, where a tick is 1024us, or ~ 1ms. Use 0 for an indefinite entry)
+ sleepmode -- RA's sleep mode (currently unused)
+ snr -- SNR in the link to RA (currently unused)
+ precursor -- predecessor in direct routes
+
+fwt_list_route
+ This command is equivalent to fwt_list.
+
+fwt_list_neigh
+ This command is used to list a neighbor from the FWT table. The only
+ parameter is the neighbor ID. If you want to list all the neighbors in a
+ table, start with nid=0, and keep incrementing nid until you get a
+ "(null)" string. Note that the nid from a fwt_list_route command can be
+ used as an input to this command. Also note that this command is meant
+ mostly for debugging. It is expected that users will use fwt_lookup.
+ One important reason for this is that the neighbor id may change as the
+ neighbor table is altered.
+
+ iwpriv ethX fwt_list_neigh nid
+
+ The output is a string of the following form:
+
+ ra sleepmode snr references
+
+ where the different fields are:-
+ ra -- RA MAC address (in the form "00:11:22:33:44:55")
+ sleepmode -- RA's sleep mode (currently unused)
+ snr -- SNR in the link to RA (currently unused)
+ references -- RA's reference counter
+
+fwt_reset
+ This command is used to reset the FWT table, getting rid of all the
+ entries. There are no input parameters.
+
+ iwpriv ethX fwt_reset
+
+ The command does not return anything.
+
+fwt_cleanup
+ This command is used to perform user-based garbage recollection. The
+ FWT table is checked, and all the entries that are expired or invalid
+ are cleaned. Note that this is exported to the driver for debugging
+ purposes, as garbage collection is also fired by the firmware when in
+ space problems. There are no input parameters.
+
+ iwpriv ethX fwt_cleanup
+
+ The command does returns the number of invalid/expired routes deleted.
+
+fwt_time
+ This command returns a card's internal time representation. It is this
+ time that is used to represent the expiration times of FWT entries. The
+ number is not consistent from card to card; it is simply a timer count.
+ The fwt_time command is used to inspect the timer so that expiration
+ times reported by fwt_list can be properly interpreted.
+
+ iwpriv ethX fwt_time
+
+mesh_get_ttl
+
+ The mesh ttl is the number of hops a mesh packet can traverse before it
+ is dropped. This parameter is used to prevent infinite loops in the
+ mesh network. The value returned by this function is the ttl assigned
+ to all mesh packets. Currently there is no way to control the ttl on a
+ per packet or per socket basis.
+
+ iwpriv ethX mesh_get_ttl
+
+mesh_set_ttl ttl
+
+ Set the ttl. The argument must be between 0 and 255.
+
+ iwpriv ethX mesh_set_ttl <ttl>
+
+mesh_get_bcastr
+
+ Shows the rate index used for mesh broadcast and multicast packets.
+ Rates are expressed in 2 * Mb/s, ie 11Mb/s is 22, 5.5Mb/s is 11, etc.
+
+ iwpriv ethX mesh_get_bcastr rate
+
+mesh_set_bcastr rate
+
+ Sets the rate index for mesh broadcast and muticast packets. Rates are
+ expressed in expressed in 2 * Mb/s, ie 11Mb/s is 22, 5.5Mb/s is 11, etc.
+
+ iwpriv ethX mesh_set_bcastr rate
+
+get_rreq_delay
+
+ Shows the delay to forward a RREQ frame. This delay allows the node to
+ forward just the best route in case the same RREQ arrives to the node
+ through different routes. The argument is shown in 1/100 seconds.
+
+ iwpriv ethX get_rreq_delay
+
+set_rreq_delay delay
+
+ Sets the RREQ forward delay. The delay is interpreted as 1/100 seconds.
+
+ iwpriv ethX set_rreq_delay delay
+
+get_route_exp
+
+ Shows the mesh route expiration time, in seconds.
+
+ iwpriv ethX get_route_exp
+
+set_route_exp time
+
+ Gets the mesh route, expiration time, in seconds.
+
+ iwpriv ethX set_route_exp time
+
+get_link_costs
+
+ Gets the mesh hop base cost for each used rate. The output gives us the
+ base cost for hops at 54Mbps, 36Mbps, 11Mbps and 1Mbps, in that order.
+ The base cost gets divided by a battery state factor to get the actual
+ cost. A cost of 0 means that rate is deactivated.
+
+ iwpriv ethX get_link_costs
+
+set_link_costs "cost54 cost36 cost11 cost1"
+
+ Sets the mesh hop base cost for the used speeds. The input parameter
+ will specify the cost for hops at 54Mbps, 36Mbps, 11Mbps and 1Mbps, in
+ that order. A cost of 0 will disable a specific rate.
+
+ iwpriv ethX set_link_costs "cost54 cost36 cost11 cost1"
+
=========================
ETHTOOL
=========================