]> rtime.felk.cvut.cz Git - socketcan-devel.git/log
socketcan-devel.git
16 years agoAdd support for #elif.
thuermann [Mon, 17 Sep 2007 07:59:34 +0000 (07:59 +0000)]
Add support for #elif.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@465 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoNew Version 20070916
hartkopp [Sun, 16 Sep 2007 16:42:29 +0000 (16:42 +0000)]
New Version 20070916

git-svn-id: svn://svn.berlios.de//socketcan/trunk@464 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved SET_MODULE_OWNER() macros for Kernel 2.6.24 and newer.
hartkopp [Sun, 16 Sep 2007 16:07:08 +0000 (16:07 +0000)]
Removed SET_MODULE_OWNER() macros for Kernel 2.6.24 and newer.

Reference:
[NET]: Nuke SET_MODULE_OWNER macro.

It's been a useless no-op for long enough in 2.6 so I figured it's time to
remove it.  The number of people that could object because they're
maintaining unified 2.4 and 2.6 drivers is probably rather small.

[ Handled drivers added by netdev tree and some missed IRDA cases... -DaveM ]

http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=commit;h=d19ef7a45e8f177e27fe8b085a68f0f3d68c7a05

git-svn-id: svn://svn.berlios.de//socketcan/trunk@463 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved SET_MODULE_OWNER() macros for Kernel 2.6.24 and newer.
hartkopp [Sun, 16 Sep 2007 16:03:01 +0000 (16:03 +0000)]
Removed SET_MODULE_OWNER() macros for Kernel 2.6.24 and newer.

Reference:
[NET]: Nuke SET_MODULE_OWNER macro.

It's been a useless no-op for long enough in 2.6 so I figured it's time to
remove it.  The number of people that could object because they're
maintaining unified 2.4 and 2.6 drivers is probably rather small.

[ Handled drivers added by netdev tree and some missed IRDA cases... -DaveM ]

http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=commit;h=d19ef7a45e8f177e27fe8b085a68f0f3d68c7a05

git-svn-id: svn://svn.berlios.de//socketcan/trunk@462 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoSupport network namespaces introduced in the current net-2.6.24 GIT tree:
hartkopp [Fri, 14 Sep 2007 08:31:46 +0000 (08:31 +0000)]
Support network namespaces introduced in the current net-2.6.24 GIT tree:

David Miller's 2.6.24 networking tree
http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=summary

[NET]: Make /proc/net per network namespace
http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=commitdiff;h=39954fef318243ead56486775160c65f92ec092f

git-svn-id: svn://svn.berlios.de//socketcan/trunk@461 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUse proc_net_remove(x) instead of remove_proc_entry(x, proc_net) to
hartkopp [Fri, 14 Sep 2007 08:10:30 +0000 (08:10 +0000)]
Use proc_net_remove(x) instead of remove_proc_entry(x, proc_net) to
have the changes for net_namespace similar to other sources.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@460 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChanged procfs handling to depend from proc_net directory.
hartkopp [Fri, 14 Sep 2007 07:27:56 +0000 (07:27 +0000)]
Changed procfs handling to depend from proc_net directory.
It looks like there is no 'nice' solution to get the broadcast managers
procfs entries under /proc/net/can/bcm/* as we would need to publish the
/proc/net/can directory reference to all CAN protocol modules.
Therefore the BCM entries are attached to /proc/net/can-bcm/* for now.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@459 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoSupport network namespaces introduced in the current net-2.6.24 GIT tree:
hartkopp [Thu, 13 Sep 2007 17:41:34 +0000 (17:41 +0000)]
Support network namespaces introduced in the current net-2.6.24 GIT tree:

David Miller's 2.6.24 networking tree
http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=summary

[NET]: Make the device list and device lookups per namespace.
http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=commitdiff;h=19dcccd778b49378287317c6c31ee763ebe08bd0

[NET]: Make socket creation namespace safe.
http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=commitdiff;h=07fee2eb642a99726ba71111bcad7180ba5479f0

[NET]: Make packet reception network namespace safe
http://git.kernel.org/?p=linux/kernel/git/davem/net-2.6.24.git;a=commitdiff;h=6de5b5062e26475050ebd88b33d3c056faa72c3f

TODO: Repair the current procfs support.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@458 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdated the canplayer to accept logfile timestamps in the future (which
hartkopp [Fri, 7 Sep 2007 11:15:22 +0000 (11:15 +0000)]
Updated the canplayer to accept logfile timestamps in the future (which
is very nice when you don't have a RTC and your systemtime is somewhere
in the 1970's :)
Added a new commandline option to skip timestamp jumps greater than x
seconds to allow to concatenate different logfiles that replay
constantly and not waiting for the absolute timestamp offsets.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@457 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdate to patch-series to revision 455.
thuermann [Fri, 3 Aug 2007 14:08:42 +0000 (14:08 +0000)]
Update to patch-series to revision 455.
Rebase from net-2.6.23 to net-2.6.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@456 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved "unused variable i" warning for the dry-run testing.
hartkopp [Fri, 3 Aug 2007 11:17:10 +0000 (11:17 +0000)]
Removed "unused variable i" warning for the dry-run testing.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@455 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed inclusion of uaccess.h that had to be made Kernel version dependend.
hartkopp [Fri, 3 Aug 2007 07:58:20 +0000 (07:58 +0000)]
Fixed inclusion of uaccess.h that had to be made Kernel version dependend.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@454 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed Kernel version dependend irqflags.
hartkopp [Fri, 3 Aug 2007 07:49:30 +0000 (07:49 +0000)]
Fixed Kernel version dependend irqflags.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@453 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded module parameter for irq_mode to force the driver to use
hartkopp [Fri, 3 Aug 2007 07:32:55 +0000 (07:32 +0000)]
Added module parameter for irq_mode to force the driver to use
non-shared interrupt handling and to let the Linux Kernel disable local
interrupts when processing the irq handler.
Fixed irqflags defines that have been changed from 2.6.17 to 2.6.18 and
not (like the irq handler) from 2.6.18 to 2.6.19.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@452 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed a character swap typo.
hartkopp [Thu, 2 Aug 2007 19:21:24 +0000 (19:21 +0000)]
Fixed a character swap typo.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@451 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoNew Version 20070802
hartkopp [Thu, 2 Aug 2007 11:29:24 +0000 (11:29 +0000)]
New Version 20070802

git-svn-id: svn://svn.berlios.de//socketcan/trunk@450 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoReduced the comments for the loopback parameter of the vcan driver to point
hartkopp [Thu, 2 Aug 2007 11:28:16 +0000 (11:28 +0000)]
Reduced the comments for the loopback parameter of the vcan driver to point
out the 'testing' use-case and to reduce the confusion which may come up
the known 'loopback' interface in Linux.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@449 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved the CCAN driver from the default targets analogue to the mscan
hartkopp [Wed, 25 Jul 2007 12:24:21 +0000 (12:24 +0000)]
Removed the CCAN driver from the default targets analogue to the mscan
driver. As these drivers only compile on special ARCHs they should not
compile by default after SVN checkout.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@448 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed in-kerneltree compilation
skallweit [Wed, 25 Jul 2007 12:02:04 +0000 (12:02 +0000)]
Fixed in-kerneltree compilation

git-svn-id: svn://svn.berlios.de//socketcan/trunk@447 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years ago- removed obsolete kernel version check
skallweit [Wed, 25 Jul 2007 11:55:21 +0000 (11:55 +0000)]
- removed obsolete kernel version check
- renamed ccan_(un)register to (un)register_ccandev

git-svn-id: svn://svn.berlios.de//socketcan/trunk@446 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoCleaned up FILES-2.6 which represents the first Kernel mainlining amount.
hartkopp [Wed, 25 Jul 2007 11:54:46 +0000 (11:54 +0000)]
Cleaned up FILES-2.6 which represents the first Kernel mainlining amount.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@445 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years ago- added a new kernel module for Bosch CCAN based CAN hardware
skallweit [Wed, 25 Jul 2007 11:46:56 +0000 (11:46 +0000)]
- added a new kernel module for Bosch CCAN based CAN hardware
- added a new kernel module for the Hynix/Magnachip H7202 chip using the CCAN module

the following TODOs are still pending:

- ccan_set_mode() and it's usage is incomplete and bogus.
- ccan_set_bit_time() can be called when the device is active.
- You already handle the state changes via interrupts. The common
  variable priv->can.state should be set accordingly. ccan_get_state()
  may then just return that value.
- You already handle error interrupts. You should fill an error frame
  and send it like a normal frame with the CAN_ERR_FLAG set. Have a look
  to the  mscan driver or http://www.rts.uni-hannover.de/xenomai/lxr/source/ksrc/drivers/can/sja1000/rtcan_sja1000.c#156.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@444 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed in-kerneltree compilation with a generated patch.
hartkopp [Wed, 25 Jul 2007 11:41:27 +0000 (11:41 +0000)]
Fixed in-kerneltree compilation with a generated patch.
As Marc Klein-Budde stated the "hal" should move to platform drivers - but
until then the generated patches work so far.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@443 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMSCAN: fix bug with retry counter in mscan_set_mode()
wolf [Wed, 25 Jul 2007 11:08:11 +0000 (11:08 +0000)]
MSCAN: fix bug with retry counter in mscan_set_mode()

git-svn-id: svn://svn.berlios.de//socketcan/trunk@442 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMSCAN: remove netdev definitions already done in common the can_setup()
wolf [Wed, 25 Jul 2007 10:59:49 +0000 (10:59 +0000)]
MSCAN: remove netdev definitions already done in common the can_setup()

git-svn-id: svn://svn.berlios.de//socketcan/trunk@441 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMSCAN: adapt driver to the revise CAN device interface
wolf [Wed, 25 Jul 2007 10:45:40 +0000 (10:45 +0000)]
MSCAN: adapt driver to the revise CAN device interface

git-svn-id: svn://svn.berlios.de//socketcan/trunk@440 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMSCAN: improve coding style and further beautification
wolf [Wed, 25 Jul 2007 09:22:53 +0000 (09:22 +0000)]
MSCAN: improve coding style and further beautification

git-svn-id: svn://svn.berlios.de//socketcan/trunk@439 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded new external build system from Marc Kleine-Budde, see:
hartkopp [Sat, 21 Jul 2007 17:53:09 +0000 (17:53 +0000)]
Added new external build system from Marc Kleine-Budde, see:
https://lists.berlios.de/pipermail/socketcan-core/2007-July/000539.html
Good job! Many thanks.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@438 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved slab destructor from kmem_cache_alloc() in Kernels >= 2.6.23 .
hartkopp [Sat, 21 Jul 2007 17:40:35 +0000 (17:40 +0000)]
Removed slab destructor from kmem_cache_alloc() in Kernels >= 2.6.23 .
See http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=20c2df83d25c6a95affe6157a4c9cac4cf5ffaac

git-svn-id: svn://svn.berlios.de//socketcan/trunk@437 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoTypedefs are evil in the Linux kernel, see Greg KH's comment on
hartkopp [Tue, 17 Jul 2007 07:02:01 +0000 (07:02 +0000)]
Typedefs are evil in the Linux kernel, see Greg KH's comment on
http://www.linuxjournal.com/comment/reply/5780

Btw. our curent typedefs canid_t and can_err_mask_t definitely make
sense and do not hide any bad things that have been remarked by Greg KH.

Added come appropriate comments for the typedefs analogue to the comments
in drivers/net/netxen/netxen_nic.h that also has been introduced into
the Kernel recently.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@436 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdate patch-series to r434.
thuermann [Mon, 16 Jul 2007 20:25:39 +0000 (20:25 +0000)]
Update patch-series to r434.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@435 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoIncluding <linux/uaccess.h> instead of <asm/uaccess.h> as suggested by
hartkopp [Mon, 16 Jul 2007 17:27:48 +0000 (17:27 +0000)]
Including <linux/uaccess.h> instead of <asm/uaccess.h> as suggested by
scripts/checkpatch.pl

git-svn-id: svn://svn.berlios.de//socketcan/trunk@434 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded missing style fix.
hartkopp [Mon, 16 Jul 2007 17:26:24 +0000 (17:26 +0000)]
Added missing style fix.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@433 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved obsolete initialisation of static variables.
hartkopp [Mon, 16 Jul 2007 17:15:08 +0000 (17:15 +0000)]
Removed obsolete initialisation of static variables.
Fixed style of pointer declarations and pointer casts.
Thanks to Patrick McHardy for the hint to linux/scripts/checkpatch.pl

git-svn-id: svn://svn.berlios.de//socketcan/trunk@432 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded the blanking of 'old' data when the can_dlc decreases between two
hartkopp [Mon, 16 Jul 2007 09:52:43 +0000 (09:52 +0000)]
Added the blanking of 'old' data when the can_dlc decreases between two
receiptions of the same can_id.
Thanks to Andre Naujoks for the bug report.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@431 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded -B option to display binary content with a gap after each data byte.
hartkopp [Mon, 16 Jul 2007 08:29:28 +0000 (08:29 +0000)]
Added -B option to display binary content with a gap after each data byte.
This option is similar to -b but may exceed the 80 char boundary.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@430 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemove priv pointer from struct can_priv.
thuermann [Fri, 13 Jul 2007 10:05:21 +0000 (10:05 +0000)]
Remove priv pointer from struct can_priv.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@429 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRename struct can_device to struct can_priv.
thuermann [Fri, 13 Jul 2007 09:34:34 +0000 (09:34 +0000)]
Rename struct can_device to struct can_priv.
Use struct net_device *dev instead of struct can_device *can.
Don't use dev->get_stats() for linux 2.6.23 and later.
Some code cleanup (formatting, typos, etc.).

git-svn-id: svn://svn.berlios.de//socketcan/trunk@428 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdate patch series to r426.
thuermann [Mon, 9 Jul 2007 11:28:55 +0000 (11:28 +0000)]
Update patch series to r426.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@427 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed (formerly unmapped) register access for sja1000_probe_ship().
hartkopp [Mon, 9 Jul 2007 11:24:40 +0000 (11:24 +0000)]
Fixed (formerly unmapped) register access for sja1000_probe_ship().
Thanks to Kai Riedmann for the error report and the patch.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@426 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemove call to ether_setup().
thuermann [Mon, 9 Jul 2007 11:21:16 +0000 (11:21 +0000)]
Remove call to ether_setup().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@425 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdd patch-series for net-2.6.23.
thuermann [Mon, 9 Jul 2007 08:49:06 +0000 (08:49 +0000)]
Add patch-series for net-2.6.23.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@424 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRebase patch-series to linux-2.6.22 and update to revision r422.
thuermann [Mon, 9 Jul 2007 08:47:42 +0000 (08:47 +0000)]
Rebase patch-series to linux-2.6.22 and update to revision r422.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@423 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdate version number.
thuermann [Mon, 9 Jul 2007 08:36:23 +0000 (08:36 +0000)]
Update version number.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@422 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed compilation warning on 64bit architectures.
hartkopp [Mon, 9 Jul 2007 08:06:51 +0000 (08:06 +0000)]
Fixed compilation warning on 64bit architectures.
Thanks to Neal Probert for the hint.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@421 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemoved obsolete variable definitions.
hartkopp [Mon, 9 Jul 2007 07:24:22 +0000 (07:24 +0000)]
Removed obsolete variable definitions.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@420 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChange back %p to %08lx for pointers to prevent the 0x prefix.
thuermann [Mon, 9 Jul 2007 06:40:00 +0000 (06:40 +0000)]
Change back %p to %08lx for pointers to prevent the 0x prefix.
Change idx back to int and do double cast to prevent GCC warning.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@419 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoreordered some code in bcm_send_to_user().
hartkopp [Mon, 9 Jul 2007 06:10:18 +0000 (06:10 +0000)]
reordered some code in bcm_send_to_user().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@418 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMake skb->tail pointer access working in 2.6.22 on 64bit architectures.
hartkopp [Sun, 8 Jul 2007 18:03:29 +0000 (18:03 +0000)]
Make skb->tail pointer access working in 2.6.22 on 64bit architectures.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@417 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed compilation warning on 64bit architectures.
hartkopp [Sun, 8 Jul 2007 12:44:12 +0000 (12:44 +0000)]
Fixed compilation warning on 64bit architectures.
Thanks to Neal Probert for the hint.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@416 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed compilation warnings on 64bit architectures.
hartkopp [Sun, 8 Jul 2007 12:31:23 +0000 (12:31 +0000)]
Fixed compilation warnings on 64bit architectures.
Thanks to Neal Probert for the hint.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@415 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemove unused #define PRIVSIZE.
thuermann [Sat, 7 Jul 2007 10:01:35 +0000 (10:01 +0000)]
Remove unused #define PRIVSIZE.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@414 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoNew version 20070707 (a prefered wedding date :)
hartkopp [Sat, 7 Jul 2007 06:54:42 +0000 (06:54 +0000)]
New version 20070707 (a prefered wedding date :)
Changes since last version:
- Reverted skb->iif changes
- includes cleanup
- vcan driver supports rtnl link API (kernel versions > 2.6.23)

git-svn-id: svn://svn.berlios.de//socketcan/trunk@413 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded notification in the case of enabled loopback on driver level.
hartkopp [Sat, 7 Jul 2007 06:37:10 +0000 (06:37 +0000)]
Added notification in the case of enabled loopback on driver level.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@412 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChanged default capabilites to allow non-root users to access the CAN
hartkopp [Sat, 7 Jul 2007 06:22:17 +0000 (06:22 +0000)]
Changed default capabilites to allow non-root users to access the CAN
bus in the case of external module compilation.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@411 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFor kernels starting with 2.6.23:
thuermann [Sat, 7 Jul 2007 01:49:36 +0000 (01:49 +0000)]
For kernels starting with 2.6.23:
* Don't create vcan interfaces at module load time.
* Delete numdev module parameter.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@409 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMove vcan driver from branch vcan-rtnl to trunk.
thuermann [Sat, 7 Jul 2007 01:38:34 +0000 (01:38 +0000)]
Move vcan driver from branch vcan-rtnl to trunk.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@408 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdd vcan config tool to Makefile.
thuermann [Sat, 7 Jul 2007 01:36:36 +0000 (01:36 +0000)]
Add vcan config tool to Makefile.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@407 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdd a tool "vcan" to add/remove vcan interfaces.
thuermann [Fri, 6 Jul 2007 15:50:55 +0000 (15:50 +0000)]
Add a tool "vcan" to add/remove vcan interfaces.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@406 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFix wrong simplification when moving code from mkpatch.
thuermann [Fri, 6 Jul 2007 05:14:15 +0000 (05:14 +0000)]
Fix wrong simplification when moving code from mkpatch.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@405 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRename kv to strip-src.
thuermann [Wed, 4 Jul 2007 13:45:06 +0000 (13:45 +0000)]
Rename kv to strip-src.
Move code to strip ident lines from mkpatch to strip-src.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@400 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoReverted the use of skb->iif in the rx path that has been introduced in
hartkopp [Fri, 29 Jun 2007 16:13:03 +0000 (16:13 +0000)]
Reverted the use of skb->iif in the rx path that has been introduced in
rev 385 and rev 386 after some discussions with Patrick McHardy and
Jamal Hadi. Indeed the use of skb->cb is the correct way to transport
the interface index inside the socket queue to the userspace. This is
also made like this in the packet socket. So the use of skb->dev is save
and it was the right way to do it, like we had done it for a long time :-)

git-svn-id: svn://svn.berlios.de//socketcan/trunk@399 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded mainly socket.h and skbuff.h and reordered the #includes to be
hartkopp [Wed, 27 Jun 2007 17:53:59 +0000 (17:53 +0000)]
Added mainly socket.h and skbuff.h and reordered the #includes to be
similar in all files.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@398 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agonew Version 20070627.
hartkopp [Wed, 27 Jun 2007 15:00:49 +0000 (15:00 +0000)]
new Version 20070627.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@397 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded missing include if_arp.h for the use of ARPHRD_CAN in notifier.
hartkopp [Wed, 27 Jun 2007 14:59:03 +0000 (14:59 +0000)]
Added missing include if_arp.h for the use of ARPHRD_CAN in notifier.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@396 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdated LDISC number to 17 (16 is occupied in the Kernel)
hartkopp [Mon, 25 Jun 2007 13:05:43 +0000 (13:05 +0000)]
Updated LDISC number to 17 (16 is occupied in the Kernel)

git-svn-id: svn://svn.berlios.de//socketcan/trunk@395 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded option '-x' to disable local loopback for sent CAN frames.
hartkopp [Fri, 22 Jun 2007 08:33:18 +0000 (08:33 +0000)]
Added option '-x' to disable local loopback for sent CAN frames.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@394 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChanged option name '-l' to '-x' as this option should also go into canplayer.
hartkopp [Fri, 22 Jun 2007 08:25:34 +0000 (08:25 +0000)]
Changed option name '-l' to '-x' as this option should also go into canplayer.
Cosmetics in print_help().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@393 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded option '-l' to disable local loopback for generated data.
hartkopp [Fri, 22 Jun 2007 08:04:48 +0000 (08:04 +0000)]
Added option '-l' to disable local loopback for generated data.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@392 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdate patch series to r390 and rebase it to linux-2.6.22-rc5-git5.
thuermann [Fri, 22 Jun 2007 03:39:34 +0000 (03:39 +0000)]
Update patch series to r390 and rebase it to linux-2.6.22-rc5-git5.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@391 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoCosmetics: Making all multiline comments look equal.
hartkopp [Thu, 21 Jun 2007 16:43:42 +0000 (16:43 +0000)]
Cosmetics: Making all multiline comments look equal.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@390 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemove wrong comment, cf. linux/net/core/dev.c:dev_queue_xmit_nit().
thuermann [Thu, 21 Jun 2007 13:33:03 +0000 (13:33 +0000)]
Remove wrong comment, cf. linux/net/core/dev.c:dev_queue_xmit_nit().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@389 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoIndeed in this context skb->input_dev could not be zero. So reverting my last
hartkopp [Thu, 21 Jun 2007 13:15:32 +0000 (13:15 +0000)]
Indeed in this context skb->input_dev could not be zero. So reverting my last
change.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@388 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded check for possible NULL pointer dereference.
hartkopp [Thu, 21 Jun 2007 13:11:17 +0000 (13:11 +0000)]
Added check for possible NULL pointer dereference.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@387 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdd (untested) support for kernels before 2.6.21.
thuermann [Thu, 21 Jun 2007 13:02:24 +0000 (13:02 +0000)]
Add (untested) support for kernels before 2.6.21.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@386 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUse skb->iif instead of skb->cb to pass the receiving interface
thuermann [Thu, 21 Jun 2007 11:57:49 +0000 (11:57 +0000)]
Use skb->iif instead of skb->cb to pass the receiving interface
up the rx path.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@385 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemove struct raw_opt and bcm_opt and integrate them into
thuermann [Thu, 21 Jun 2007 10:29:54 +0000 (10:29 +0000)]
Remove struct raw_opt and bcm_opt and integrate them into
struct raw_scok resp. struct bcm_sock directly.
Add (untested) support for kernels < 2.6.12.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@384 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAargh, got trailing white-space wrong again. Fixed it.
thuermann [Wed, 20 Jun 2007 12:09:30 +0000 (12:09 +0000)]
Aargh, got trailing white-space wrong again.  Fixed it.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@383 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChange comments according to coding style document.
thuermann [Wed, 20 Jun 2007 12:03:49 +0000 (12:03 +0000)]
Change comments according to coding style document.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@382 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFix race condition in raw_getsockopt().
thuermann [Wed, 20 Jun 2007 11:39:10 +0000 (11:39 +0000)]
Fix race condition in raw_getsockopt().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@381 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoCosmetic changes only: white-space, line breaks, comments, etc.
thuermann [Wed, 20 Jun 2007 11:06:33 +0000 (11:06 +0000)]
Cosmetic changes only: white-space, line breaks, comments, etc.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@380 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdated to version 20070619.
hartkopp [Tue, 19 Jun 2007 19:15:00 +0000 (19:15 +0000)]
Updated to version 20070619.
Removed '#' in kernel log banner at module startup.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@379 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMoved sk_error_report() call outside lock_sock(sk) analogue to notifier
hartkopp [Tue, 19 Jun 2007 18:48:40 +0000 (18:48 +0000)]
Moved sk_error_report() call outside lock_sock(sk) analogue to notifier
code in bcm.c and other kernel source.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@378 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoMove branch ha/locktest to trunk/kernel/2.6, making it the ne trunk version.
thuermann [Tue, 19 Jun 2007 18:26:21 +0000 (18:26 +0000)]
Move branch ha/locktest to trunk/kernel/2.6, making it the ne trunk version.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@377 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoRemove 2.6 kernel code to replace it with the version from
thuermann [Tue, 19 Jun 2007 18:24:38 +0000 (18:24 +0000)]
Remove 2.6 kernel code to replace it with the version from
branch ha/locktest.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@376 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded program exit on SIOCGIFINDEX error.
hartkopp [Mon, 18 Jun 2007 20:04:23 +0000 (20:04 +0000)]
Added program exit on SIOCGIFINDEX error.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@370 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoDisabled obsolte receive filter. Added error checking for SIOCGIFINDEX.
hartkopp [Mon, 18 Jun 2007 19:59:20 +0000 (19:59 +0000)]
Disabled obsolte receive filter. Added error checking for SIOCGIFINDEX.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@369 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded option '-e' to hold the socket open even when errors like ENETDOWN or
hartkopp [Thu, 14 Jun 2007 06:31:15 +0000 (06:31 +0000)]
Added option '-e' to hold the socket open even when errors like ENETDOWN or
ENODEV occur at runtime.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@354 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFix: Remove allocated filter, even when socket was not bound.
hartkopp [Mon, 11 Jun 2007 20:03:23 +0000 (20:03 +0000)]
Fix: Remove allocated filter, even when socket was not bound.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@339 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded error handling in raw_setsockopt().
hartkopp [Mon, 11 Jun 2007 19:59:11 +0000 (19:59 +0000)]
Added error handling in raw_setsockopt().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@338 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded complete error handling in raw_bind().
hartkopp [Mon, 11 Jun 2007 19:28:56 +0000 (19:28 +0000)]
Added complete error handling in raw_bind().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@337 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoIntroduced return value to raw_[add|remove]_filters() to communicate
hartkopp [Mon, 11 Jun 2007 16:51:54 +0000 (16:51 +0000)]
Introduced return value to raw_[add|remove]_filters() to communicate
can_rx_(un)register() problems.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@336 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed can_dev_register() to work even when the interface is not up.
hartkopp [Mon, 11 Jun 2007 16:15:42 +0000 (16:15 +0000)]
Fixed can_dev_register() to work even when the interface is not up.
Moved debug output to position, where *dev is valid.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@335 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChanged prototypes for CAN core exported functions to use ifindex
hartkopp [Sun, 10 Jun 2007 18:21:58 +0000 (18:21 +0000)]
Changed prototypes for CAN core exported functions to use ifindex
instead of *dev to hold the dev-pointer only very local and to reduce
locking issues.
Removed some handling in the raw/bcm notifiers that caused the system to
crash, when removing the network driver under heavy load on the fly.
TODO:
Put notifier into protocol opt structure to make kmalloc/kfree obsolete.
Handle the notifiers with RCU lists.
Put notifier list 'device dependend' into dev_rcv_lists.
After that check for better notifier handling.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@334 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUpdated receive timestamp handling for Kernel Versions >= 2.6.22
hartkopp [Fri, 8 Jun 2007 06:50:54 +0000 (06:50 +0000)]
Updated receive timestamp handling for Kernel Versions >= 2.6.22

git-svn-id: svn://svn.berlios.de//socketcan/trunk@333 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoChanges for new loopback handling analogue to CAN core.
hartkopp [Wed, 6 Jun 2007 15:11:04 +0000 (15:11 +0000)]
Changes for new loopback handling analogue to CAN core.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@332 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoAdded new skb->pkt_type in received skb's.
hartkopp [Wed, 6 Jun 2007 15:04:24 +0000 (15:04 +0000)]
Added new skb->pkt_type in received skb's.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@331 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoFixed missing sk reference in af_can.c / deliver().
hartkopp [Wed, 6 Jun 2007 14:52:51 +0000 (14:52 +0000)]
Fixed missing sk reference in af_can.c / deliver().
Cosmetics.

git-svn-id: svn://svn.berlios.de//socketcan/trunk@330 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoUse skb->pkt_type and skb->sk instead of skb->cb to pass loopback
thuermann [Wed, 6 Jun 2007 13:55:23 +0000 (13:55 +0000)]
Use skb->pkt_type and skb->sk instead of skb->cb to pass loopback
flag and originating socket to netdevice drivers and back to raw_rcv().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@329 030b6a49-0b11-0410-94ab-b0dab22257f2

16 years agoSet skb->pkt_type on CAN frames looped back from can_send().
thuermann [Wed, 6 Jun 2007 13:40:05 +0000 (13:40 +0000)]
Set skb->pkt_type on CAN frames looped back from can_send().

git-svn-id: svn://svn.berlios.de//socketcan/trunk@328 030b6a49-0b11-0410-94ab-b0dab22257f2