Skip to content

Commit 36432da

Browse files
committed
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
2 parents 440f0d5 + bb40080 commit 36432da

File tree

518 files changed

+20731
-11363
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

518 files changed

+20731
-11363
lines changed

Documentation/feature-removal-schedule.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -437,3 +437,10 @@ Why: Superseded by tdfxfb. I2C/DDC support used to live in a separate
437437
driver but this caused driver conflicts.
438438
Who: Jean Delvare <khali@linux-fr.org>
439439
Krzysztof Helt <krzysztof.h1@wp.pl>
440+
441+
---------------------------
442+
443+
What: CONFIG_RFKILL_INPUT
444+
When: 2.6.33
445+
Why: Should be implemented in userspace, policy daemon.
446+
Who: Johannes Berg <johannes@sipsolutions.net>

Documentation/isdn/INTERFACE.CAPI

Lines changed: 90 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ From then on, Kernel CAPI may call the registered callback functions for the
4545
device.
4646

4747
If the device becomes unusable for any reason (shutdown, disconnect ...), the
48-
driver has to call capi_ctr_reseted(). This will prevent further calls to the
48+
driver has to call capi_ctr_down(). This will prevent further calls to the
4949
callback functions by Kernel CAPI.
5050

5151

@@ -114,20 +114,36 @@ char *driver_name
114114
int (*load_firmware)(struct capi_ctr *ctrlr, capiloaddata *ldata)
115115
(optional) pointer to a callback function for sending firmware and
116116
configuration data to the device
117+
Return value: 0 on success, error code on error
118+
Called in process context.
117119

118120
void (*reset_ctr)(struct capi_ctr *ctrlr)
119-
pointer to a callback function for performing a reset on the device,
120-
releasing all registered applications
121+
(optional) pointer to a callback function for performing a reset on
122+
the device, releasing all registered applications
123+
Called in process context.
121124

122125
void (*register_appl)(struct capi_ctr *ctrlr, u16 applid,
123126
capi_register_params *rparam)
124127
void (*release_appl)(struct capi_ctr *ctrlr, u16 applid)
125128
pointers to callback functions for registration and deregistration of
126129
applications with the device
130+
Calls to these functions are serialized by Kernel CAPI so that only
131+
one call to any of them is active at any time.
127132

128133
u16 (*send_message)(struct capi_ctr *ctrlr, struct sk_buff *skb)
129134
pointer to a callback function for sending a CAPI message to the
130135
device
136+
Return value: CAPI error code
137+
If the method returns 0 (CAPI_NOERROR) the driver has taken ownership
138+
of the skb and the caller may no longer access it. If it returns a
139+
non-zero (error) value then ownership of the skb returns to the caller
140+
who may reuse or free it.
141+
The return value should only be used to signal problems with respect
142+
to accepting or queueing the message. Errors occurring during the
143+
actual processing of the message should be signaled with an
144+
appropriate reply message.
145+
Calls to this function are not serialized by Kernel CAPI, ie. it must
146+
be prepared to be re-entered.
131147

132148
char *(*procinfo)(struct capi_ctr *ctrlr)
133149
pointer to a callback function returning the entry for the device in
@@ -138,6 +154,8 @@ read_proc_t *ctr_read_proc
138154
system entry, /proc/capi/controllers/<n>; will be called with a
139155
pointer to the device's capi_ctr structure as the last (data) argument
140156

157+
Note: Callback functions are never called in interrupt context.
158+
141159
- to be filled in before calling capi_ctr_ready():
142160

143161
u8 manu[CAPI_MANUFACTURER_LEN]
@@ -153,6 +171,45 @@ u8 serial[CAPI_SERIAL_LEN]
153171
value to return for CAPI_GET_SERIAL
154172

155173

174+
4.3 The _cmsg Structure
175+
176+
(declared in <linux/isdn/capiutil.h>)
177+
178+
The _cmsg structure stores the contents of a CAPI 2.0 message in an easily
179+
accessible form. It contains members for all possible CAPI 2.0 parameters, of
180+
which only those appearing in the message type currently being processed are
181+
actually used. Unused members should be set to zero.
182+
183+
Members are named after the CAPI 2.0 standard names of the parameters they
184+
represent. See <linux/isdn/capiutil.h> for the exact spelling. Member data
185+
types are:
186+
187+
u8 for CAPI parameters of type 'byte'
188+
189+
u16 for CAPI parameters of type 'word'
190+
191+
u32 for CAPI parameters of type 'dword'
192+
193+
_cstruct for CAPI parameters of type 'struct' not containing any
194+
variably-sized (struct) subparameters (eg. 'Called Party Number')
195+
The member is a pointer to a buffer containing the parameter in
196+
CAPI encoding (length + content). It may also be NULL, which will
197+
be taken to represent an empty (zero length) parameter.
198+
199+
_cmstruct for CAPI parameters of type 'struct' containing 'struct'
200+
subparameters ('Additional Info' and 'B Protocol')
201+
The representation is a single byte containing one of the values:
202+
CAPI_DEFAULT: the parameter is empty
203+
CAPI_COMPOSE: the values of the subparameters are stored
204+
individually in the corresponding _cmsg structure members
205+
206+
Functions capi_cmsg2message() and capi_message2cmsg() are provided to convert
207+
messages between their transport encoding described in the CAPI 2.0 standard
208+
and their _cmsg structure representation. Note that capi_cmsg2message() does
209+
not know or check the size of its destination buffer. The caller must make
210+
sure it is big enough to accomodate the resulting CAPI message.
211+
212+
156213
5. Lower Layer Interface Functions
157214

158215
(declared in <linux/isdn/capilli.h>)
@@ -166,7 +223,7 @@ int detach_capi_ctr(struct capi_ctr *ctrlr)
166223
register/unregister a device (controller) with Kernel CAPI
167224

168225
void capi_ctr_ready(struct capi_ctr *ctrlr)
169-
void capi_ctr_reseted(struct capi_ctr *ctrlr)
226+
void capi_ctr_down(struct capi_ctr *ctrlr)
170227
signal controller ready/not ready
171228

172229
void capi_ctr_suspend_output(struct capi_ctr *ctrlr)
@@ -211,3 +268,32 @@ CAPIMSG_CONTROL(m) CAPIMSG_SETCONTROL(m, contr) Controller/PLCI/NCCI
211268
(u32)
212269
CAPIMSG_DATALEN(m) CAPIMSG_SETDATALEN(m, len) Data Length (u16)
213270

271+
272+
Library functions for working with _cmsg structures
273+
(from <linux/isdn/capiutil.h>):
274+
275+
unsigned capi_cmsg2message(_cmsg *cmsg, u8 *msg)
276+
Assembles a CAPI 2.0 message from the parameters in *cmsg, storing the
277+
result in *msg.
278+
279+
unsigned capi_message2cmsg(_cmsg *cmsg, u8 *msg)
280+
Disassembles the CAPI 2.0 message in *msg, storing the parameters in
281+
*cmsg.
282+
283+
unsigned capi_cmsg_header(_cmsg *cmsg, u16 ApplId, u8 Command, u8 Subcommand,
284+
u16 Messagenumber, u32 Controller)
285+
Fills the header part and address field of the _cmsg structure *cmsg
286+
with the given values, zeroing the remainder of the structure so only
287+
parameters with non-default values need to be changed before sending
288+
the message.
289+
290+
void capi_cmsg_answer(_cmsg *cmsg)
291+
Sets the low bit of the Subcommand field in *cmsg, thereby converting
292+
_REQ to _CONF and _IND to _RESP.
293+
294+
char *capi_cmd2str(u8 Command, u8 Subcommand)
295+
Returns the CAPI 2.0 message name corresponding to the given command
296+
and subcommand values, as a static ASCII string. The return value may
297+
be NULL if the command/subcommand is not one of those defined in the
298+
CAPI 2.0 standard.
299+
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
2+
Linux IEEE 802.15.4 implementation
3+
4+
5+
Introduction
6+
============
7+
8+
The Linux-ZigBee project goal is to provide complete implementation
9+
of IEEE 802.15.4 / ZigBee / 6LoWPAN protocols. IEEE 802.15.4 is a stack
10+
of protocols for organizing Low-Rate Wireless Personal Area Networks.
11+
12+
Currently only IEEE 802.15.4 layer is implemented. We have choosen
13+
to use plain Berkeley socket API, the generic Linux networking stack
14+
to transfer IEEE 802.15.4 messages and a special protocol over genetlink
15+
for configuration/management
16+
17+
18+
Socket API
19+
==========
20+
21+
int sd = socket(PF_IEEE802154, SOCK_DGRAM, 0);
22+
.....
23+
24+
The address family, socket addresses etc. are defined in the
25+
include/net/ieee802154/af_ieee802154.h header or in the special header
26+
in our userspace package (see either linux-zigbee sourceforge download page
27+
or git tree at git://linux-zigbee.git.sourceforge.net/gitroot/linux-zigbee).
28+
29+
One can use SOCK_RAW for passing raw data towards device xmit function. YMMV.
30+
31+
32+
MLME - MAC Level Management
33+
============================
34+
35+
Most of IEEE 802.15.4 MLME interfaces are directly mapped on netlink commands.
36+
See the include/net/ieee802154/nl802154.h header. Our userspace tools package
37+
(see above) provides CLI configuration utility for radio interfaces and simple
38+
coordinator for IEEE 802.15.4 networks as an example users of MLME protocol.
39+
40+
41+
Kernel side
42+
=============
43+
44+
Like with WiFi, there are several types of devices implementing IEEE 802.15.4.
45+
1) 'HardMAC'. The MAC layer is implemented in the device itself, the device
46+
exports MLME and data API.
47+
2) 'SoftMAC' or just radio. These types of devices are just radio transceivers
48+
possibly with some kinds of acceleration like automatic CRC computation and
49+
comparation, automagic ACK handling, address matching, etc.
50+
51+
Those types of devices require different approach to be hooked into Linux kernel.
52+
53+
54+
HardMAC
55+
=======
56+
57+
See the header include/net/ieee802154/netdevice.h. You have to implement Linux
58+
net_device, with .type = ARPHRD_IEEE802154. Data is exchanged with socket family
59+
code via plain sk_buffs. The control block of sk_buffs will contain additional
60+
info as described in the struct ieee802154_mac_cb.
61+
62+
To hook the MLME interface you have to populate the ml_priv field of your
63+
net_device with a pointer to struct ieee802154_mlme_ops instance. All fields are
64+
required.
65+
66+
We provide an example of simple HardMAC driver at drivers/ieee802154/fakehard.c
67+
68+
69+
SoftMAC
70+
=======
71+
72+
We are going to provide intermediate layer impelementing IEEE 802.15.4 MAC
73+
in software. This is currently WIP.
74+
75+
See header include/net/ieee802154/mac802154.h and several drivers in
76+
drivers/ieee802154/

Documentation/networking/ip-sysctl.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1057,6 +1057,13 @@ disable_ipv6 - BOOLEAN
10571057
address.
10581058
Default: FALSE (enable IPv6 operation)
10591059

1060+
When this value is changed from 1 to 0 (IPv6 is being enabled),
1061+
it will dynamically create a link-local address on the given
1062+
interface and start Duplicate Address Detection, if necessary.
1063+
1064+
When this value is changed from 0 to 1 (IPv6 is being disabled),
1065+
it will dynamically delete all address on the given interface.
1066+
10601067
accept_dad - INTEGER
10611068
Whether to accept DAD (Duplicate Address Detection).
10621069
0: Disable DAD

Documentation/networking/ipv6.txt

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,40 @@ disable
3333

3434
A reboot is required to enable IPv6.
3535

36+
autoconf
37+
38+
Specifies whether to enable IPv6 address autoconfiguration
39+
on all interfaces. This might be used when one does not wish
40+
for addresses to be automatically generated from prefixes
41+
received in Router Advertisements.
42+
43+
The possible values and their effects are:
44+
45+
0
46+
IPv6 address autoconfiguration is disabled on all interfaces.
47+
48+
Only the IPv6 loopback address (::1) and link-local addresses
49+
will be added to interfaces.
50+
51+
1
52+
IPv6 address autoconfiguration is enabled on all interfaces.
53+
54+
This is the default value.
55+
56+
disable_ipv6
57+
58+
Specifies whether to disable IPv6 on all interfaces.
59+
This might be used when no IPv6 addresses are desired.
60+
61+
The possible values and their effects are:
62+
63+
0
64+
IPv6 is enabled on all interfaces.
65+
66+
This is the default value.
67+
68+
1
69+
IPv6 is disabled on all interfaces.
70+
71+
No IPv6 addresses will be added to interfaces.
72+
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
Memory mapped SJA1000 CAN controller from NXP (formerly Philips)
2+
3+
Required properties:
4+
5+
- compatible : should be "nxp,sja1000".
6+
7+
- reg : should specify the chip select, address offset and size required
8+
to map the registers of the SJA1000. The size is usually 0x80.
9+
10+
- interrupts: property with a value describing the interrupt source
11+
(number and sensitivity) required for the SJA1000.
12+
13+
Optional properties:
14+
15+
- nxp,external-clock-frequency : Frequency of the external oscillator
16+
clock in Hz. Note that the internal clock frequency used by the
17+
SJA1000 is half of that value. If not specified, a default value
18+
of 16000000 (16 MHz) is used.
19+
20+
- nxp,tx-output-mode : operation mode of the TX output control logic:
21+
<0x0> : bi-phase output mode
22+
<0x1> : normal output mode (default)
23+
<0x2> : test output mode
24+
<0x3> : clock output mode
25+
26+
- nxp,tx-output-config : TX output pin configuration:
27+
<0x01> : TX0 invert
28+
<0x02> : TX0 pull-down (default)
29+
<0x04> : TX0 pull-up
30+
<0x06> : TX0 push-pull
31+
<0x08> : TX1 invert
32+
<0x10> : TX1 pull-down
33+
<0x20> : TX1 pull-up
34+
<0x30> : TX1 push-pull
35+
36+
- nxp,clock-out-frequency : clock frequency in Hz on the CLKOUT pin.
37+
If not specified or if the specified value is 0, the CLKOUT pin
38+
will be disabled.
39+
40+
- nxp,no-comparator-bypass : Allows to disable the CAN input comperator.
41+
42+
For futher information, please have a look to the SJA1000 data sheet.
43+
44+
Examples:
45+
46+
can@3,100 {
47+
compatible = "nxp,sja1000";
48+
reg = <3 0x100 0x80>;
49+
interrupts = <2 0>;
50+
interrupt-parent = <&mpic>;
51+
nxp,external-clock-frequency = <16000000>;
52+
};
53+

0 commit comments

Comments
 (0)