xref: /freebsd/sys/contrib/device-tree/Bindings/net/can/sja1000.txt (revision c66ec88fed842fbaad62c30d510644ceb7bd2d71)
1*c66ec88fSEmmanuel VadotMemory mapped SJA1000 CAN controller from NXP (formerly Philips)
2*c66ec88fSEmmanuel Vadot
3*c66ec88fSEmmanuel VadotRequired properties:
4*c66ec88fSEmmanuel Vadot
5*c66ec88fSEmmanuel Vadot- compatible : should be one of "nxp,sja1000", "technologic,sja1000".
6*c66ec88fSEmmanuel Vadot
7*c66ec88fSEmmanuel Vadot- reg : should specify the chip select, address offset and size required
8*c66ec88fSEmmanuel Vadot	to map the registers of the SJA1000. The size is usually 0x80.
9*c66ec88fSEmmanuel Vadot
10*c66ec88fSEmmanuel Vadot- interrupts: property with a value describing the interrupt source
11*c66ec88fSEmmanuel Vadot	(number and sensitivity) required for the SJA1000.
12*c66ec88fSEmmanuel Vadot
13*c66ec88fSEmmanuel VadotOptional properties:
14*c66ec88fSEmmanuel Vadot
15*c66ec88fSEmmanuel Vadot- reg-io-width : Specify the size (in bytes) of the IO accesses that
16*c66ec88fSEmmanuel Vadot	should be performed on the device.  Valid value is 1, 2 or 4.
17*c66ec88fSEmmanuel Vadot	This property is ignored for technologic version.
18*c66ec88fSEmmanuel Vadot	Default to 1 (8 bits).
19*c66ec88fSEmmanuel Vadot
20*c66ec88fSEmmanuel Vadot- nxp,external-clock-frequency : Frequency of the external oscillator
21*c66ec88fSEmmanuel Vadot	clock in Hz. Note that the internal clock frequency used by the
22*c66ec88fSEmmanuel Vadot	SJA1000 is half of that value. If not specified, a default value
23*c66ec88fSEmmanuel Vadot	of 16000000 (16 MHz) is used.
24*c66ec88fSEmmanuel Vadot
25*c66ec88fSEmmanuel Vadot- nxp,tx-output-mode : operation mode of the TX output control logic:
26*c66ec88fSEmmanuel Vadot	<0x0> : bi-phase output mode
27*c66ec88fSEmmanuel Vadot	<0x1> : normal output mode (default)
28*c66ec88fSEmmanuel Vadot	<0x2> : test output mode
29*c66ec88fSEmmanuel Vadot	<0x3> : clock output mode
30*c66ec88fSEmmanuel Vadot
31*c66ec88fSEmmanuel Vadot- nxp,tx-output-config : TX output pin configuration:
32*c66ec88fSEmmanuel Vadot	<0x01> : TX0 invert
33*c66ec88fSEmmanuel Vadot	<0x02> : TX0 pull-down (default)
34*c66ec88fSEmmanuel Vadot	<0x04> : TX0 pull-up
35*c66ec88fSEmmanuel Vadot	<0x06> : TX0 push-pull
36*c66ec88fSEmmanuel Vadot	<0x08> : TX1 invert
37*c66ec88fSEmmanuel Vadot	<0x10> : TX1 pull-down
38*c66ec88fSEmmanuel Vadot	<0x20> : TX1 pull-up
39*c66ec88fSEmmanuel Vadot	<0x30> : TX1 push-pull
40*c66ec88fSEmmanuel Vadot
41*c66ec88fSEmmanuel Vadot- nxp,clock-out-frequency : clock frequency in Hz on the CLKOUT pin.
42*c66ec88fSEmmanuel Vadot	If not specified or if the specified value is 0, the CLKOUT pin
43*c66ec88fSEmmanuel Vadot	will be disabled.
44*c66ec88fSEmmanuel Vadot
45*c66ec88fSEmmanuel Vadot- nxp,no-comparator-bypass : Allows to disable the CAN input comparator.
46*c66ec88fSEmmanuel Vadot
47*c66ec88fSEmmanuel VadotFor further information, please have a look to the SJA1000 data sheet.
48*c66ec88fSEmmanuel Vadot
49*c66ec88fSEmmanuel VadotExamples:
50*c66ec88fSEmmanuel Vadot
51*c66ec88fSEmmanuel Vadotcan@3,100 {
52*c66ec88fSEmmanuel Vadot	compatible = "nxp,sja1000";
53*c66ec88fSEmmanuel Vadot	reg = <3 0x100 0x80>;
54*c66ec88fSEmmanuel Vadot	interrupts = <2 0>;
55*c66ec88fSEmmanuel Vadot	interrupt-parent = <&mpic>;
56*c66ec88fSEmmanuel Vadot	nxp,external-clock-frequency = <16000000>;
57*c66ec88fSEmmanuel Vadot};
58*c66ec88fSEmmanuel Vadot
59