Re: [PATCH RFC 22/39] mmc: block: Prepare CQE data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 15/02/17 15:49, Linus Walleij wrote:
> On Fri, Feb 10, 2017 at 1:55 PM, Adrian Hunter <adrian.hunter@xxxxxxxxx> wrote:
> 
>> Enhance mmc_blk_data_prep() to support CQE requests.
>>
>> Signed-off-by: Adrian Hunter <adrian.hunter@xxxxxxxxx>
> 
> Hey:
> 
>> +#include <linux/ioprio.h>
> (...)
>> +       if (IOPRIO_PRIO_CLASS(req_get_ioprio(req)) == IOPRIO_CLASS_RT)
>> +               brq->data.flags |= MMC_DATA_PRIO;
> 
> What is this?

It is the command queue priority.

The command queue supports 2 priorities: "high" (1) and "simple" (0).  The
eMMC will give "high" priority tasks priority over "simple" priority tasks.

So here we give priority to IOPRIO_CLASS_RT which seems appropriate.

> 
> Why are we not already doing this and why is it not a separate patch?

I think adding a comment is better since it is a command queue feature.

> 
>>         /*
>>          * Data tag is used only during writing meta data to speed
>>          * up write and any subsequent read of this meta data
>>          */
> 
> Is this comment still true?

AFAIK

> 
>> -       *do_data_tag = card->ext_csd.data_tag_unit_size &&
>> -                      (req->cmd_flags & REQ_META) &&
>> -                      (rq_data_dir(req) == WRITE) &&
>> -                      ((brq->data.blocks * brq->data.blksz) >=
>> -                       card->ext_csd.data_tag_unit_size);
>> +       do_data_tag = card->ext_csd.data_tag_unit_size &&
>> +                     (req->cmd_flags & REQ_META) &&
>> +                     (rq_data_dir(req) == WRITE) &&
>> +                     ((brq->data.blocks * brq->data.blksz) >=
>> +                      card->ext_csd.data_tag_unit_size);
>> +
>> +       if (do_data_tag)
>> +               brq->data.flags |= MMC_DATA_DAT_TAG;
> 
> Because it seems to be more unconditionally used now.

The key ingredient is (req->cmd_flags & REQ_META) i.e. meta-data gets tagged.


--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux