From e39526e6e7a96904c9f1c85375d49ff437c18c44 Mon Sep 17 00:00:00 2001 From: Ed L Cashin Date: Fri, 19 Aug 2005 16:54:43 -0400 Subject: [PATCH] aoe [1/2]: support 16 AoE slot addresses per AoE shelf Change the number of supported AoE slot addresses per AoE shelf address to 16. Signed-off-by: Ed L. Cashin Signed-off-by: Greg Kroah-Hartman --- drivers/block/aoe/aoe.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'drivers') diff --git a/drivers/block/aoe/aoe.h b/drivers/block/aoe/aoe.h index 721ba8086043..599951dc2c3b 100644 --- a/drivers/block/aoe/aoe.h +++ b/drivers/block/aoe/aoe.h @@ -7,12 +7,12 @@ * default is 16, which is 15 partitions plus the whole disk */ #ifndef AOE_PARTITIONS -#define AOE_PARTITIONS 16 +#define AOE_PARTITIONS (16) #endif -#define SYSMINOR(aoemajor, aoeminor) ((aoemajor) * 10 + (aoeminor)) -#define AOEMAJOR(sysminor) ((sysminor) / 10) -#define AOEMINOR(sysminor) ((sysminor) % 10) +#define SYSMINOR(aoemajor, aoeminor) ((aoemajor) * NPERSHELF + (aoeminor)) +#define AOEMAJOR(sysminor) ((sysminor) / NPERSHELF) +#define AOEMINOR(sysminor) ((sysminor) % NPERSHELF) #define WHITESPACE " \t\v\f\n" enum { @@ -83,7 +83,7 @@ enum { enum { MAXATADATA = 1024, - NPERSHELF = 10, + NPERSHELF = 16, /* number of slots per shelf address */ FREETAG = -1, MIN_BUFS = 8, }; -- cgit v1.2.2 From 49a1fd60d2a8e671222515cf6055e91781278517 Mon Sep 17 00:00:00 2001 From: Ed L Cashin Date: Fri, 19 Aug 2005 17:05:21 -0400 Subject: [PATCH] aoe [2/2]: update driver version number to twelve Update driver version number to twelve. Signed-off-by: Ed L. Cashin Signed-off-by: Greg Kroah-Hartman --- drivers/block/aoe/aoe.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/block/aoe/aoe.h b/drivers/block/aoe/aoe.h index 599951dc2c3b..0e9e586e9ba3 100644 --- a/drivers/block/aoe/aoe.h +++ b/drivers/block/aoe/aoe.h @@ -1,5 +1,5 @@ /* Copyright (c) 2004 Coraid, Inc. See COPYING for GPL terms. */ -#define VERSION "10" +#define VERSION "12" #define AOE_MAJOR 152 #define DEVICE_NAME "aoe" -- cgit v1.2.2 From 877599fdef5ea4a7dd1956e22fa9d6923add97f8 Mon Sep 17 00:00:00 2001 From: Evgeniy Polyakov Date: Mon, 12 Sep 2005 17:12:43 +0400 Subject: [PATCH] crc16: remove w1 specific comments. Remove w1 comments from crc16.h and move specific constants into w1_ds2433.c where they are used. Replace %d with %zd. Signed-off-by: Evgeniy Polyakov Signed-off-by: Greg Kroah-Hartman --- drivers/w1/w1_ds2433.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/w1/w1_ds2433.c b/drivers/w1/w1_ds2433.c index b7c24b34d270..279e0e0363d6 100644 --- a/drivers/w1/w1_ds2433.c +++ b/drivers/w1/w1_ds2433.c @@ -15,6 +15,10 @@ #include #ifdef CONFIG_W1_F23_CRC #include + +#define CRC16_INIT 0 +#define CRC16_VALID 0xb001 + #endif #include "w1.h" @@ -214,7 +218,7 @@ static ssize_t w1_f23_write_bin(struct kobject *kobj, char *buf, loff_t off, #ifdef CONFIG_W1_F23_CRC /* can only write full blocks in cached mode */ if ((off & W1_PAGE_MASK) || (count & W1_PAGE_MASK)) { - dev_err(&sl->dev, "invalid offset/count off=%d cnt=%d\n", + dev_err(&sl->dev, "invalid offset/count off=%d cnt=%zd\n", (int)off, count); return -EINVAL; } -- cgit v1.2.2