Re: [PATCH v2] mmc: enable trim in eMMC device

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

 



As my understanding, if erase will be used by default, MMC_CAP_ERASE flags can be removed. isn't?

Best Regards,
Jaehoon Chung

On 02/11/2014 07:54 AM, Puthikorn Voravootivat wrote:
> Force all host to have erase capacity to enable trim or
> discard feature in supported eMMC device.
> 
> Signed-off-by: Puthikorn Voravootivat <puthik@xxxxxxxxxxxx>
> ---
> V2 change:
> Instead of add MMC_CAP_ERASE just only for dw_mmc, this patch adds
> this capability to all host.
> 
>  drivers/mmc/core/host.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/mmc/core/host.c b/drivers/mmc/core/host.c
> index 49bc403..a21f590 100644
> --- a/drivers/mmc/core/host.c
> +++ b/drivers/mmc/core/host.c
> @@ -521,6 +521,8 @@ int mmc_add_host(struct mmc_host *host)
>  	WARN_ON((host->caps & MMC_CAP_SDIO_IRQ) &&
>  		!host->ops->enable_sdio_irq);
>  
> +	host->caps |= MMC_CAP_ERASE;
> +
>  	err = device_add(&host->class_dev);
>  	if (err)
>  		return err;
> 

--
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