Skip to content

Commit

Permalink
can: CAN Network device driver and Netlink interface
Browse files Browse the repository at this point in the history
The CAN network device driver interface provides a generic interface to
setup, configure and monitor CAN network devices. It exports a set of
common data structures and functions, which all real CAN network device
drivers should use. Please have a look to the SJA1000 or MSCAN driver
to understand how to use them. The name of the module is can-dev.ko.

Furthermore, it adds a Netlink interface allowing to configure the CAN
device using the program "ip" from the iproute2 utility suite.

For further information please check "Documentation/networking/can.txt"

Signed-off-by: Wolfgang Grandegger <wg@grandegger.com>
Signed-off-by: Oliver Hartkopp <oliver.hartkopp@volkswagen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Wolfgang Grandegger authored and David S. Miller committed May 18, 2009
1 parent 4261a20 commit 39549ee
Show file tree
Hide file tree
Showing 6 changed files with 869 additions and 0 deletions.
23 changes: 23 additions & 0 deletions drivers/net/can/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,29 @@ config CAN_VCAN
This driver can also be built as a module. If so, the module
will be called vcan.

config CAN_DEV
tristate "Platform CAN drivers with Netlink support"
depends on CAN
default Y
---help---
Enables the common framework for platform CAN drivers with Netlink
support. This is the standard library for CAN drivers.
If unsure, say Y.

config CAN_CALC_BITTIMING
bool "CAN bit-timing calculation"
depends on CAN_DEV
default Y
---help---
If enabled, CAN bit-timing parameters will be calculated for the
bit-rate specified via Netlink argument "bitrate" when the device
get started. This works fine for the most common CAN controllers
with standard bit-rates but may fail for exotic bit-rates or CAN
source clock frequencies. Disabling saves some space, but then the
bit-timing parameters must be specified directly using the Netlink
arguments "tq", "prop_seg", "phase_seg1", "phase_seg2" and "sjw".
If unsure, say Y.

config CAN_DEBUG_DEVICES
bool "CAN devices debugging messages"
depends on CAN
Expand Down
5 changes: 5 additions & 0 deletions drivers/net/can/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,8 @@
#

obj-$(CONFIG_CAN_VCAN) += vcan.o

obj-$(CONFIG_CAN_DEV) += can-dev.o
can-dev-y := dev.o

ccflags-$(CONFIG_CAN_DEBUG_DEVICES) := -DDEBUG
Loading

0 comments on commit 39549ee

Please sign in to comment.