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  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 30 Aug 2006 09:39:17 -0400
From:	James Bottomley <James.Bottomley@...elEye.com>
To:	Ed Lin <ed.lin@...mise.com>
Cc:	Jens Axboe <axboe@...e.de>,
	linux-scsi <linux-scsi@...r.kernel.org>,
	linux-kernel <linux-kernel@...r.kernel.org>,
	akpm <akpm@...l.org>, promise_linux <promise_linux@...mise.com>,
	jeff <jeff@...zik.org>
Subject: Re: [PATCH 3/3] stex: use block layer tagging

On Wed, 2006-08-30 at 17:30 +0800, Ed Lin wrote:
> +stex_slave_alloc(struct scsi_device *sdev)
> +{
> +       struct st_hba *hba = (struct st_hba *) sdev->host->hostdata;
> +       unsigned long flags;
> +
> +       /*
> +        * this should be done in slave_configure routine. but we need
> +        * tagging ever since the first command. we can't wait...
> +        */
> +       spin_lock_irqsave(hba->host->host_lock, flags);
> +       if (hba->devnum++ == 0) {
> +               if (blk_queue_init_tags(sdev->request_queue,
> +                               hba->host->can_queue, NULL) == 0) {
> +                       hba->ref = 1;
> +                       hba->shared_queue = sdev->request_queue;
> +               }
> +       } else if (hba->ref) {
> +               blk_queue_init_tags(sdev->request_queue,
> +                       hba->host->can_queue,
> hba->shared_queue->queue_tags);
> +               hba->ref++;
> +       }
> +
> +       if (hba->ref) {
> +               sdev->tagged_supported = 1;
> +               scsi_set_tag_type(sdev, MSG_SIMPLE_TAG);
> +               scsi_adjust_queue_depth(sdev,
> +                       scsi_get_tag_type(sdev),
> hba->host->can_queue);
> +       } else
> +               sdev->tagged_supported = 0;
> +       spin_unlock_irqrestore(hba->host->host_lock, flags);

OK, this is indicating an inherent problem in using the shared tag maps.
I talked a bit with Jens and we think there's a way to eliminate most of
this and collapse it down to a simple SCSI helper.  I'll post the two
patches separately, but basically when its done your slave alloc should
become a simple scsi_activate_tcq().

James


-
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ