linux-can.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* SocketCAN version numbering
@ 2012-04-27  9:25 Heinz-Jürgen Oertel
  2012-04-27  9:43 ` Oliver Hartkopp
  2012-04-27  9:46 ` Wolfgang Grandegger
  0 siblings, 2 replies; 3+ messages in thread
From: Heinz-Jürgen Oertel @ 2012-04-27  9:25 UTC (permalink / raw)
  To: linux-can

[-- Attachment #1: Type: Text/Plain, Size: 341 bytes --]


Hello,

What is the suggested way to get the SocketCAN version number?
On my two systems, according to Documentation/networking/can.txt, I always get 

 $ cat /proc/net/can/version
 rev 20090105 abi 8

on different systems.
But one has support for error counters the other not with the same interface board

Regards
    Heinz

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 190 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: SocketCAN version numbering
  2012-04-27  9:25 SocketCAN version numbering Heinz-Jürgen Oertel
@ 2012-04-27  9:43 ` Oliver Hartkopp
  2012-04-27  9:46 ` Wolfgang Grandegger
  1 sibling, 0 replies; 3+ messages in thread
From: Oliver Hartkopp @ 2012-04-27  9:43 UTC (permalink / raw)
  To: Heinz-Jürgen Oertel; +Cc: linux-can

On 27.04.2012 11:25, Heinz-Jürgen Oertel wrote:

> What is the suggested way to get the SocketCAN version number?
> On my two systems, according to Documentation/networking/can.txt, I always get
>
>   $ cat /proc/net/can/version
>   rev 20090105 abi 8
>
> on different systems.
> But one has support for error counters the other not with the same interface board

Hello Heinz,

the version number is intended for the network layer stuff located in
linux/net/can and not for the CAN drivers.

Generally the version number is obsolete as it is part of the Kernel and
therefore e.g. the ABI for applications has to be stable and backwards
compatible.

Btw. i think when adding support for CAN FD we should indicate that with a
new version number and ABI version 9.

When there are new functionalities that are implemented in a specific Kernel
version, you may use the uname() function to retrieve the Kernel version.

http://www.kernel.org/doc/man-pages/online/pages/man2/uname.2.html

Or check if a new function is known or not.

Regards,
Oliver

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: SocketCAN version numbering
  2012-04-27  9:25 SocketCAN version numbering Heinz-Jürgen Oertel
  2012-04-27  9:43 ` Oliver Hartkopp
@ 2012-04-27  9:46 ` Wolfgang Grandegger
  1 sibling, 0 replies; 3+ messages in thread
From: Wolfgang Grandegger @ 2012-04-27  9:46 UTC (permalink / raw)
  To: Heinz-Jürgen Oertel; +Cc: linux-can

Hello Heinz,

On 04/27/2012 11:25 AM, Heinz-Jürgen Oertel wrote:
> 
> Hello,
> 
> What is the suggested way to get the SocketCAN version number?
> On my two systems, according to Documentation/networking/can.txt, I always get 
> 
>  $ cat /proc/net/can/version
>  rev 20090105 abi 8

This is for the CAN protocol implementation but I'm not sure if it's
well maintained...

> on different systems.
> But one has support for error counters the other not with the same interface board

... and for CAN drives we do not maintain extra version number. Usually,
the kernel version is used to understand if a feature exists or is
supported. For the bus error counter and such features, capability flags
would be a nice to have, though Anyway, what would you like to use the
berr_counters for? If they are not available, a netlink request will
return an error.

Wolfgang.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-04-27  9:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-27  9:25 SocketCAN version numbering Heinz-Jürgen Oertel
2012-04-27  9:43 ` Oliver Hartkopp
2012-04-27  9:46 ` Wolfgang Grandegger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).