On 2020/5/15 12:19, Matthew Wilcox wrote:
> On Thu, May 07, 2020 at 03:50:57PM +0800, Zhen Lei wrote:
>> +++ b/block/blk-settings.c
>> @@ -150,7 +150,7 @@ void blk_queue_max_hw_sectors(struct request_queue *q,
>> unsigned int max_hw_secto
>> unsigned int max_sectors;
>>
>> if ((max_
On Thu, May 07, 2020 at 03:50:57PM +0800, Zhen Lei wrote:
> +++ b/block/blk-settings.c
> @@ -150,7 +150,7 @@ void blk_queue_max_hw_sectors(struct request_queue *q,
> unsigned int max_hw_secto
> unsigned int max_sectors;
>
> if ((max_hw_sectors << 9) < PAGE_SIZE) {
> - max
1. Replace "1 << (PAGE_SHIFT - 9)" with PAGE_SECTORS
2. Replace ">> (PAGE_SHIFT - 9)" with sectors_to_npage()
Suggested-by: Matthew Wilcox
Signed-off-by: Zhen Lei
---
block/blk-settings.c| 6 +++---
block/partitions/core.c | 5 ++---
2 files changed, 5 insertions(+), 6 deletions(-)
diff --
3 matches
Mail list logo