lkml.org 
[lkml]   [2021]   [Apr]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mtd: core: Constify buf in mtd_write_user_prot_reg()
Hi Tudor,

Tudor Ambarus <tudor.ambarus@microchip.com> wrote on Sat, 3 Apr 2021
09:09:31 +0300:

> The write buffer comes from user and should be const.
> Constify write buffer in mtd core and across all _write_user_prot_reg()
> users. cfi_cmdset_{0001, 0002} and onenand_base will pay the cost of an
> explicit cast to discard the const qualifier since the beginning, since
> they are using an otp_op_t function prototype that is used for both reads
> and writes. mtd_dataflash and SPI NOR will benefit of the const buffer
> because they are using different paths for writes and reads.
>
> Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>

Applied on top of mtd/next after the merge of all our internal PR's.

Thanks,
Miquèl

\
 
 \ /
  Last update: 2021-04-16 20:34    [W:0.164 / U:0.320 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site