diff mbox series

[v3,net-next] sfc: fix ia64 builds without CONFIG_RTC_LIB

Message ID 20230218005620.31221-1-alejandro.lucero-palau@amd.com (mailing list archive)
State Changes Requested
Delegated to: Netdev Maintainers
Headers show
Series [v3,net-next] sfc: fix ia64 builds without CONFIG_RTC_LIB | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
netdev/cover_letter success Single patches do not need cover letters
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers success CCed 9 of 9 maintainers
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success Fixes tag looks correct
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 8 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Lucero Palau, Alejandro Feb. 18, 2023, 12:56 a.m. UTC
From: Alejandro Lucero <alejandro.lucero-palau@amd.com>

Add an embarrassingly missed semicolon plus and embarrassingly missed
parenthesis breaking kernel building in ia64 configs.

Reported-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/oe-kbuild-all/202302170047.EjCPizu3-lkp@intel.com/
Fixes: 14743ddd2495 ("sfc: add devlink info support for ef100")
Signed-off-by: Alejandro Lucero <alejandro.lucero-palau@amd.com>
---
 drivers/net/ethernet/sfc/efx_devlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Simon Horman Feb. 19, 2023, 1:24 p.m. UTC | #1
Hi Alejandro,

On Sat, Feb 18, 2023 at 12:56:20AM +0000, alejandro.lucero-palau@amd.com wrote:
> From: Alejandro Lucero <alejandro.lucero-palau@amd.com>
> 
> Add an embarrassingly missed semicolon plus and embarrassingly missed
> parenthesis breaking kernel building in ia64 configs.

I think this statement is slightly misleading.

The problem may have manifested when building for ia64 config.
However, I don't believe that it is, strictly speaking, an ia64 issue.
Rather, I believe the problem is build without CONFIG_RTC_LIB.

Some architectures select CONFIG_RTC_LIB., f.e. x86_64. But some do not.
ia64 is one such example. arm64 is another - indeed I was able to reproduce
the bug when building for arm64 using config based on the one at the link
below.

I think it would be helpful to update the patch description accordingly.

Code change looks good to me: I exercised builds for both ia64 and arm64.

> Reported-by: kernel test robot <lkp@intel.com>
> Link: https://lore.kernel.org/oe-kbuild-all/202302170047.EjCPizu3-lkp@intel.com/
> Fixes: 14743ddd2495 ("sfc: add devlink info support for ef100")
> Signed-off-by: Alejandro Lucero <alejandro.lucero-palau@amd.com>
> ---
>  drivers/net/ethernet/sfc/efx_devlink.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/sfc/efx_devlink.c b/drivers/net/ethernet/sfc/efx_devlink.c
> index d2eb6712ba35..c829362ca99f 100644
> --- a/drivers/net/ethernet/sfc/efx_devlink.c
> +++ b/drivers/net/ethernet/sfc/efx_devlink.c
> @@ -323,7 +323,7 @@ static void efx_devlink_info_running_v2(struct efx_nic *efx,
>  				    GET_VERSION_V2_OUT_SUCFW_BUILD_DATE);
>  		rtc_time64_to_tm(tstamp, &build_date);
>  #else
> -		memset(&build_date, 0, sizeof(build_date)
> +		memset(&build_date, 0, sizeof(build_date));
>  #endif
>  		build_id = MCDI_DWORD(outbuf, GET_VERSION_V2_OUT_SUCFW_CHIP_ID);
>  
> -- 
> 2.17.1
>
Lucero Palau, Alejandro Feb. 20, 2023, 10:27 a.m. UTC | #2
On 2/19/23 13:24, Simon Horman wrote:
> Hi Alejandro,
>
> On Sat, Feb 18, 2023 at 12:56:20AM +0000, alejandro.lucero-palau@amd.com wrote:
>> From: Alejandro Lucero <alejandro.lucero-palau@amd.com>
>>
>> Add an embarrassingly missed semicolon plus and embarrassingly missed
>> parenthesis breaking kernel building in ia64 configs.
> I think this statement is slightly misleading.
>
> The problem may have manifested when building for ia64 config.
> However, I don't believe that it is, strictly speaking, an ia64 issue.
> Rather, I believe the problem is build without CONFIG_RTC_LIB.
>
> Some architectures select CONFIG_RTC_LIB., f.e. x86_64. But some do not.
> ia64 is one such example. arm64 is another - indeed I was able to reproduce
> the bug when building for arm64 using config based on the one at the link
> below.
>
> I think it would be helpful to update the patch description accordingly.
>
> Code change looks good to me: I exercised builds for both ia64 and arm64.
>
Hi Simon,

I agree. In fact, I did not initially specify ia64 in the subject, but I 
got a warning suggesting maybe I should do it.

I guess that suggestion is likely due to adding the Reported and Link 
tags, but as you say, it is not describing the problem properly.

I will change it in v4.

Thanks, and thank you for testing.

>> Reported-by: kernel test robot <lkp@intel.com>
>> Link: https://lore.kernel.org/oe-kbuild-all/202302170047.EjCPizu3-lkp@intel.com/
>> Fixes: 14743ddd2495 ("sfc: add devlink info support for ef100")
>> Signed-off-by: Alejandro Lucero <alejandro.lucero-palau@amd.com>
>> ---
>>   drivers/net/ethernet/sfc/efx_devlink.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/net/ethernet/sfc/efx_devlink.c b/drivers/net/ethernet/sfc/efx_devlink.c
>> index d2eb6712ba35..c829362ca99f 100644
>> --- a/drivers/net/ethernet/sfc/efx_devlink.c
>> +++ b/drivers/net/ethernet/sfc/efx_devlink.c
>> @@ -323,7 +323,7 @@ static void efx_devlink_info_running_v2(struct efx_nic *efx,
>>   				    GET_VERSION_V2_OUT_SUCFW_BUILD_DATE);
>>   		rtc_time64_to_tm(tstamp, &build_date);
>>   #else
>> -		memset(&build_date, 0, sizeof(build_date)
>> +		memset(&build_date, 0, sizeof(build_date));
>>   #endif
>>   		build_id = MCDI_DWORD(outbuf, GET_VERSION_V2_OUT_SUCFW_CHIP_ID);
>>   
>> -- 
>> 2.17.1
>>
Simon Horman Feb. 20, 2023, 10:36 a.m. UTC | #3
On Mon, Feb 20, 2023 at 10:27:01AM +0000, Lucero Palau, Alejandro wrote:
> 
> On 2/19/23 13:24, Simon Horman wrote:
> > Hi Alejandro,
> >
> > On Sat, Feb 18, 2023 at 12:56:20AM +0000, alejandro.lucero-palau@amd.com wrote:
> >> From: Alejandro Lucero <alejandro.lucero-palau@amd.com>
> >>
> >> Add an embarrassingly missed semicolon plus and embarrassingly missed
> >> parenthesis breaking kernel building in ia64 configs.
> > I think this statement is slightly misleading.
> >
> > The problem may have manifested when building for ia64 config.
> > However, I don't believe that it is, strictly speaking, an ia64 issue.
> > Rather, I believe the problem is build without CONFIG_RTC_LIB.
> >
> > Some architectures select CONFIG_RTC_LIB., f.e. x86_64. But some do not.
> > ia64 is one such example. arm64 is another - indeed I was able to reproduce
> > the bug when building for arm64 using config based on the one at the link
> > below.
> >
> > I think it would be helpful to update the patch description accordingly.
> >
> > Code change looks good to me: I exercised builds for both ia64 and arm64.
> >
> Hi Simon,
> 
> I agree. In fact, I did not initially specify ia64 in the subject, but I 
> got a warning suggesting maybe I should do it.
> 
> I guess that suggestion is likely due to adding the Reported and Link 
> tags, but as you say, it is not describing the problem properly.
> 
> I will change it in v4.
> 
> Thanks, and thank you for testing.

Likewise, thanks.
diff mbox series

Patch

diff --git a/drivers/net/ethernet/sfc/efx_devlink.c b/drivers/net/ethernet/sfc/efx_devlink.c
index d2eb6712ba35..c829362ca99f 100644
--- a/drivers/net/ethernet/sfc/efx_devlink.c
+++ b/drivers/net/ethernet/sfc/efx_devlink.c
@@ -323,7 +323,7 @@  static void efx_devlink_info_running_v2(struct efx_nic *efx,
 				    GET_VERSION_V2_OUT_SUCFW_BUILD_DATE);
 		rtc_time64_to_tm(tstamp, &build_date);
 #else
-		memset(&build_date, 0, sizeof(build_date)
+		memset(&build_date, 0, sizeof(build_date));
 #endif
 		build_id = MCDI_DWORD(outbuf, GET_VERSION_V2_OUT_SUCFW_CHIP_ID);