Rename macro VERSION to CAN_VERSION, now defined in core.h.
Add macro CAN_ABI_VERSION.
Don't include version.h in kernel patches and delete usage of RCSID()
from all files generated by mkpatch.
git-svn-id: svn://svn.berlios.de//socketcan/trunk@217
030b6a49-0b11-0410-94ab-
b0dab22257f2
kernel/2.6/net/can/bcm.c
kernel/2.6/include/linux/can.h
kernel/2.6/include/linux/can/core.h
-kernel/2.6/include/linux/can/version.h
kernel/2.6/include/linux/can/error.h
kernel/2.6/include/linux/can/raw.h
kernel/2.6/include/linux/can/bcm.h
RCSID("$Id$");
-static __initdata const char banner[] = KERN_INFO
- "CAN: serial line CAN interface " VERSION "\n";
+static __initdata const char banner[] =
+ KERN_INFO "CAN: serial line CAN interface " CAN_VERSION "\n";
MODULE_ALIAS_LDISC(N_SLCAN);
MODULE_DESCRIPTION("serial line CAN interface");
RCSID("$Id$");
-static __initdata const char banner[] = KERN_INFO "CAN: virtual CAN "
- "interface " VERSION "\n";
+static __initdata const char banner[] =
+ KERN_INFO "CAN: virtual CAN interface " CAN_VERSION "\n";
MODULE_DESCRIPTION("virtual CAN interface");
MODULE_LICENSE("Dual BSD/GPL");
#include <linux/skbuff.h>
#include <linux/netdevice.h>
+
+#define CAN_VERSION "2.0.0-pre6"
+
+/* increment this number each time you change some user-space interface */
+#define CAN_ABI_VERSION 8
+
#define DNAME(dev) ((dev) ? (dev)->name : "any")
#define CAN_PROC_DIR "net/can" /* /proc/... */
RCSID("$Id$");
-#define MAJORVERSION 2
-#define MINORVERSION 0
-#define PATCHLEVEL 0
-#define EXTRAVERSION "-pre6"
-
-#define LLCF_VERSION_CODE (((MAJORVERSION) << 16) + ((MINORVERSION) << 8) \
- + (PATCHLEVEL))
-
-/* stringification: these are the usual macros to stringify with macro
- expansion. The str() macro does the expansion, the xstr() macro is
- for the actual stringification.
-*/
-#define str(arg) xstr(arg)
-#define xstr(arg) #arg
-
-#define VERSION str(MAJORVERSION) "." str(MINORVERSION) "." str(PATCHLEVEL) \
- EXTRAVERSION
-
#endif /* CAN_VERSION_H */
RCSID("$Id$");
#define IDENT "af_can"
-static __initdata const char banner[] = KERN_INFO "CAN: Controller Area "
- "Network PF_CAN core " VERSION "\n";
+static __initdata const char banner[] =
+ KERN_INFO "CAN: Controller Area Network PF_CAN core " CAN_VERSION "\n";
MODULE_DESCRIPTION("Controller Area Network PF_CAN core");
MODULE_LICENSE("Dual BSD/GPL");
#define IDENT "bcm"
static __initdata const char banner[] = KERN_INFO
- "CAN: broadcast manager (bcm) socket protocol " VERSION "\n";
+ "CAN: broadcast manager (bcm) socket protocol " CAN_VERSION "\n";
MODULE_DESCRIPTION("PF_CAN bcm sockets");
MODULE_LICENSE("Dual BSD/GPL");
int len = 0;
len += snprintf(page + len, PAGE_SIZE - len,
- "%06X [ Volkswagen Group - Low Level CAN Framework"
- " (LLCF) v%s ]\n", LLCF_VERSION_CODE, VERSION);
+ "CAN version %s, ABI version %d",
+ CAN_VERSION, CAN_ABI_VERSION);
*eof = 1;
return len;
}
RCSID("$Id$");
#define IDENT "raw"
-static __initdata const char banner[] = KERN_INFO "CAN: raw socket protocol"
- " " VERSION "\n";
+static __initdata const char banner[] =
+ KERN_INFO "CAN: raw socket protocol " CAN_VERSION "\n";
MODULE_DESCRIPTION("PF_CAN raw sockets");
MODULE_LICENSE("Dual BSD/GPL");
# Generate a kernel patch to add socketcan to a kernel src tree.
# The list of files to be added is read from stdin.
+use POSIX qw(strftime);
+
$version = shift;
if (-r "patches/$version.diff") {
open file, "./kv $version $file |" || die "open $file\n";
@lines = <file>;
$count = $#lines + 1;
- use POSIX qw(strftime);
$mtime = (stat($file))[9];
$ts = strftime "%F %T", gmtime((stat($file))[9]);
+ for $i (0..$#lines) {
+ if ($lines[$i] =~ /include.*linux\/can\/version\.h/) {
+ undef($lines[$i]);
+ $count--;
+ }
+ if ($lines[$i] =~ /RCSID/) {
+ undef($lines[$i]);
+ $count--;
+ while ($lines[++$i] eq "\n") {
+ undef($lines[$i]);
+ $count--;
+ }
+ }
+ }
+
print "--- a/$name 1970-01-01 00:00:00\n";
print "+++ b/$name $ts\n";
print "@@ -0,0 +1,$count @@\n";
for (@lines) {
- print "+$_";
+ print "+$_" if (defined($_));
}
close file;
}