[U-Boot] [PATCH 2/2] mmc: rpmb: update size format for write_counter

Jaehoon Chung jh80.chung at samsung.com
Thu Jun 29 09:43:38 UTC 2017


On 06/08/2017 10:20 AM, Kever Yang wrote:
> According to MMC spec, the write_counter is 4-byte length,
> use 'int' instead of 'long' type for the 'long' is not 4-byte
> in 64 bit CPU.
> 
> Signed-off-by: Jason Zhu <jason.zhu at rock-chips.com>
> Signed-off-by: Kever Yang <kever.yang at rock-chips.com>

Applied to u-boot-mmc. Thanks!

Best Regards,
Jaehoon Chung


> ---
> 
>  drivers/mmc/rpmb.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/mmc/rpmb.c b/drivers/mmc/rpmb.c
> index 1c6888f..0b6b622 100644
> --- a/drivers/mmc/rpmb.c
> +++ b/drivers/mmc/rpmb.c
> @@ -67,7 +67,7 @@ struct s_rpmb {
>  	unsigned char mac[RPMB_SZ_MAC];
>  	unsigned char data[RPMB_SZ_DATA];
>  	unsigned char nonce[RPMB_SZ_NONCE];
> -	unsigned long write_counter;
> +	unsigned int write_counter;
>  	unsigned short address;
>  	unsigned short block_count;
>  	unsigned short result;
> 



More information about the U-Boot mailing list