From: Jens Axboe <jens.axboe-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
To: Alan Stern <stern-nwvwT67g6+6dFdvTe/nMLpVzexx5G7lz@public.gmane.org>
Cc: "Martin K. Petersen"
<martin.petersen-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>,
Ramya Desai <ramya.desai-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
James Bottomley <James.Bottomley-l3A5Bk7waGM@public.gmane.org>,
USB list <linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
SCSI development list
<linux-scsi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Greg KH <greg-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
Subject: Re: Maximum data size in a single transfer for MS driver
Date: Thu, 25 Feb 2010 18:52:10 +0100 [thread overview]
Message-ID: <20100225175210.GY1025@kernel.dk> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1002251132170.1686-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
On Thu, Feb 25 2010, Alan Stern wrote:
> On Tue, 23 Feb 2010, Martin K. Petersen wrote:
>
> > Alan> Are drivers supposed to assign values directly to
> > Alan> q-> limits.max_sectors? Shouldn't there be a cleaner API for all
> > Alan> this?
> >
> > Drivers are supposed to set the hard limit. The soft limit is a
> > fs/block layer value and none of the device driver's business.
>
> _How_ are drivers supposed to set the hard limit?
>
> If they call blk_queue_max_sectors() then both the hard and soft limits
> are affected, but at least the hard limit is set correctly.
blk_queue_max_hw_sectors(). I can understand the confusion though, the
comment is crap for blk_queue_max_sectors(). Mostly because the logic
isn't as clean as it should be, I'll try and get that cleaned up.
> If they call blk_queue_max_hw_sectors() then only the hard limit is
> affected, but it cannot be set to a value less than 1024
> (BLK_DEF_MAX_SECTORS). Wouldn't it be more logical to allow the hard
> limit to be set to anything at least as large as the page size, and
> decrease the soft limit if it is larger than the new hard limit?
The driver really should only set the hard limit, they should not change
the soft setting.
We cannot easily support < page size software not hardware limit.
--
Jens Axboe
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2010-02-25 17:52 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-17 12:37 Maximum data size in a single transfer for MS driver Ramya Desai
[not found] ` <3e7aae31002170437i52ba4ba1w10c1ff224d9b37ef-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-02-17 15:02 ` James Bottomley
2010-02-18 8:46 ` Ramya Desai
2010-02-18 15:47 ` James Bottomley
[not found] ` <1266508049.4355.37.camel-0iu6Cu4xQGLYCGPCin2YbQ@public.gmane.org>
2010-02-18 16:24 ` Alan Stern
[not found] ` <Pine.LNX.4.44L0.1002181115120.1294-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2010-02-18 16:30 ` James Bottomley
[not found] ` <1266510627.4355.41.camel-0iu6Cu4xQGLYCGPCin2YbQ@public.gmane.org>
2010-02-18 16:51 ` Alan Stern
2010-02-19 12:43 ` Ramya Desai
2010-02-19 14:26 ` James Bottomley
2010-02-22 12:50 ` Ramya Desai
[not found] ` <3e7aae31002220450o6f83d2f3n45c795d70ef01f72-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-02-22 13:06 ` James Bottomley
2010-02-22 14:15 ` Ramya Desai
2010-02-22 17:44 ` Alan Stern
2010-02-22 18:07 ` Alan Stern
[not found] ` <Pine.LNX.4.44L0.1002221232160.1251-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2010-02-23 15:29 ` Ramya Desai
2010-02-23 16:49 ` Alan Stern
2010-02-23 17:00 ` Martin K. Petersen
2010-02-23 18:01 ` Alan Stern
[not found] ` <Pine.LNX.4.44L0.1002231253320.1308-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2010-02-24 13:07 ` Ramya Desai
2010-02-24 13:12 ` Jens Axboe
2010-02-24 16:30 ` Alan Stern
2010-02-24 19:07 ` Jens Axboe
2010-02-25 14:47 ` Ramya Desai
2010-02-25 14:44 ` Ramya Desai
2010-02-25 16:37 ` Alan Stern
2010-02-25 16:49 ` Martin K. Petersen
2010-02-25 16:53 ` Martin K. Petersen
2010-02-25 17:54 ` Jens Axboe
[not found] ` <yq1zl2xl0j3.fsf-+q57XtR/GgMb6DWv4sQWN6xOck334EZe@public.gmane.org>
2010-02-25 18:28 ` Alan Stern
2010-02-25 19:05 ` Martin K. Petersen
[not found] ` <yq1iq9lkueh.fsf-+q57XtR/GgMb6DWv4sQWN6xOck334EZe@public.gmane.org>
2010-02-25 19:47 ` Alan Stern
2010-02-26 3:37 ` Martin K. Petersen
[not found] ` <Pine.LNX.4.44L0.1002251132170.1686-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2010-02-25 17:52 ` Jens Axboe [this message]
-- strict thread matches above, loose matches on Subject: below --
2010-02-25 16:59 scameron
2010-02-25 17:00 ` scameron
2010-02-25 17:18 ` scameron
2010-02-25 17:28 ` Martin K. Petersen
2010-02-25 17:41 ` Boaz Harrosh
2010-02-25 17:58 ` Martin K. Petersen
2010-02-25 19:07 ` Martin K. Petersen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100225175210.GY1025@kernel.dk \
--to=jens.axboe-qhclzuegtsvqt0dzr+alfa@public.gmane.org \
--cc=James.Bottomley-l3A5Bk7waGM@public.gmane.org \
--cc=greg-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org \
--cc=linux-scsi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=martin.petersen-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
--cc=ramya.desai-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=stern-nwvwT67g6+6dFdvTe/nMLpVzexx5G7lz@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox