lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 8 Apr 2007 11:19:02 +0100
From:	Christoph Hellwig <hch@...radead.org>
To:	Stephen Cameron <smcameron@...oo.com>
Cc:	linux-kernel@...r.kernel.org, james.bottomley@...eleye.com,
	mike.miller@...com, steve.cameron@...com
Subject: Re: [PATCH] Perverting cciss

On Fri, Apr 06, 2007 at 10:07:52AM -0700, Stephen Cameron wrote:
> How about something like this:
> (Since my mailer is sure to wreck the patch, it can be found intact here:
> http://cciss.cvs.sourceforge.net/*checkout*/cciss/patches/kernel.org-2.6/cciss_sg_io_block_pc.patch?revision=1.1

Looks good except for some codingstyle nits:

> @@ -45,7 +45,7 @@
>  #include <linux/blkdev.h>
>  #include <linux/genhd.h>
>  #include <linux/completion.h>
> -
> +#include <scsi/sg.h>

Please don't remove the empty line after the include statements.

> +	case SG_IO: return scsi_cmd_ioctl(filep, disk, cmd, argp);

should be split into two lines for readability.

Also is there a reason you don't want to pass down the various
other ioctls scsi_cmd_ioctl can handle to it?

> +				if (blk_pc_request(cmd->rq)) {
> +					if (cmd->rq->sense) {
> +						if (cmd->rq->sense_len > cmd->err_info->SenseLen)
> +							cmd->rq->sense_len = cmd->err_info->SenseLen;
> +						memcpy(cmd->rq->sense, cmd->err_info->SenseInfo, cmd->rq->sense_len);
> +					} else
> +						cmd->rq->sense_len = 0;
> +				}

Please add some linebreaks so that lines don't grow longer than 80
characters.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists