Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=e108cebb21316714de43767e242316c784471740 Commit: e108cebb21316714de43767e242316c784471740 Parent: b18a2db416088ad54a4bfb59c0b932be383aee83 Author: vignesh babu <[EMAIL PROTECTED]> AuthorDate: Fri Oct 12 16:11:39 2007 +0200 Committer: Martin Schwidefsky <[EMAIL PROTECTED]> CommitDate: Fri Oct 12 16:13:07 2007 +0200
[S390] is_power_of_2 in drivers/s390/block/dasd_int.h Replacing n & (n - 1) for power of 2 check by is_power_of_2(n) Signed-off-by: vignesh babu <[EMAIL PROTECTED]> Signed-off-by: Martin Schwidefsky <[EMAIL PROTECTED]> Signed-off-by: Heiko Carstens <[EMAIL PROTECTED]> --- drivers/s390/block/dasd_int.h | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/drivers/s390/block/dasd_int.h b/drivers/s390/block/dasd_int.h index aeda526..d427dae 100644 --- a/drivers/s390/block/dasd_int.h +++ b/drivers/s390/block/dasd_int.h @@ -53,6 +53,7 @@ #include <linux/genhd.h> #include <linux/hdreg.h> #include <linux/interrupt.h> +#include <linux/log2.h> #include <asm/ccwdev.h> #include <linux/workqueue.h> #include <asm/debug.h> @@ -456,7 +457,7 @@ dasd_free_chunk(struct list_head *chunk_list, void *mem) static inline int dasd_check_blocksize(int bsize) { - if (bsize < 512 || bsize > 4096 || (bsize & (bsize - 1)) != 0) + if (bsize < 512 || bsize > 4096 || !is_power_of_2(bsize)) return -EMEDIUMTYPE; return 0; } - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html