[PATCH 11/15] bus/dpaa: pass interface name as a string instead of pointer

Ferruh Yigit ferruh.yigit at amd.com
Thu Oct 6 11:39:36 CEST 2022


On 10/6/2022 9:51 AM, Gagandeep Singh wrote:
> 
> 
>> -----Original Message-----
>> From: Ferruh Yigit <ferruh.yigit at amd.com>
>> Sent: Wednesday, October 5, 2022 7:52 PM
>> To: Gagandeep Singh <G.Singh at nxp.com>; dev at dpdk.org
>> Cc: Rohit Raj <rohit.raj at nxp.com>
>> Subject: Re: [PATCH 11/15] bus/dpaa: pass interface name as a string instead
>> of pointer
>>
>> On 9/28/2022 6:25 AM, Gagandeep Singh wrote:
>>> From: Rohit Raj <rohit.raj at nxp.com>
>>>
>>> Due to change in latest kernel, passing the interface name to kernel
>>> through IOCTL as string instead of character pointer.
>>>
>>
>> This kernel component is the one that is delivered part of SDK I assume,
>> instead of an upstreamed one.
>>
>> What is the way for user match kernel code and DPDK driver, like is there any
>> matching version information documented?
>>
> We share the version compatible information in our internal SDK release document.
> 

That is what I thought, does it make sense to link to that information 
from DPDK documentation?

>>> Signed-off-by: Rohit Raj <rohit.raj at nxp.com>
>>> ---
>>>    drivers/bus/dpaa/base/qbman/process.c | 8 ++++----
>>>    1 file changed, 4 insertions(+), 4 deletions(-)
>>>
>>> diff --git a/drivers/bus/dpaa/base/qbman/process.c
>>> b/drivers/bus/dpaa/base/qbman/process.c
>>> index 9bc92681cd..3504ec97db 100644
>>> --- a/drivers/bus/dpaa/base/qbman/process.c
>>> +++ b/drivers/bus/dpaa/base/qbman/process.c
>>> @@ -302,7 +302,7 @@ int bman_free_raw_portal(struct dpaa_raw_portal
>> *portal)
>>>    	_IOW(DPAA_IOCTL_MAGIC, 0x0E, struct usdpaa_ioctl_link_status)
>>>
>>>    #define DPAA_IOCTL_DISABLE_LINK_STATUS_INTERRUPT \
>>> -	_IOW(DPAA_IOCTL_MAGIC, 0x0F, char*)
>>> +	_IOW(DPAA_IOCTL_MAGIC, 0x0F, char[IF_NAME_MAX_LEN])
>>>
>>>    int dpaa_intr_enable(char *if_name, int efd)
>>>    {
>>> @@ -330,7 +330,7 @@ int dpaa_intr_disable(char *if_name)
>>>    	if (ret)
>>>    		return ret;
>>>
>>> -	ret = ioctl(fd, DPAA_IOCTL_DISABLE_LINK_STATUS_INTERRUPT,
>> &if_name);
>>> +	ret = ioctl(fd, DPAA_IOCTL_DISABLE_LINK_STATUS_INTERRUPT,
>> if_name);
>>>    	if (ret) {
>>>    		if (errno == EINVAL)
>>>    			printf("Failed to disable interrupt: Not Supported\n");
>> @@ -472,7
>>> +472,7 @@ int dpaa_update_link_speed(char *if_name, int link_speed, int
>> link_duplex)
>>>    }
>>>
>>>    #define DPAA_IOCTL_RESTART_LINK_AUTONEG \
>>> -	_IOW(DPAA_IOCTL_MAGIC, 0x13, char *)
>>> +	_IOW(DPAA_IOCTL_MAGIC, 0x13, char[IF_NAME_MAX_LEN])
>>>
>>>    int dpaa_restart_link_autoneg(char *if_name)
>>>    {
>>> @@ -481,7 +481,7 @@ int dpaa_restart_link_autoneg(char *if_name)
>>>    	if (ret)
>>>    		return ret;
>>>
>>> -	ret = ioctl(fd, DPAA_IOCTL_RESTART_LINK_AUTONEG, &if_name);
>>> +	ret = ioctl(fd, DPAA_IOCTL_RESTART_LINK_AUTONEG, if_name);
>>>    	if (ret) {
>>>    		if (errno == EINVAL)
>>>    			printf("Failed to restart autoneg: Not Supported\n");
> 



More information about the dev mailing list