S32K3XX FlexCAN kconfig fix to work in conjunction with EMAC ioctl

This commit is contained in:
Peter van der Perk 2022-12-22 14:08:45 +01:00 committed by Xiang Xiao
parent 7f3cd2d3e8
commit 371f81d157

View File

@ -1639,7 +1639,7 @@ static int s32k3xx_txavail(struct net_driver_s *dev)
*
****************************************************************************/
#ifdef CONFIG_NETDEV_CAN_BITRATE_IOCTL
#ifdef CONFIG_NETDEV_IOCTL
static int s32k3xx_ioctl(struct net_driver_s *dev, int cmd,
unsigned long arg)
{
@ -1649,6 +1649,7 @@ static int s32k3xx_ioctl(struct net_driver_s *dev, int cmd,
switch (cmd)
{
#ifdef CONFIG_NETDEV_CAN_BITRATE_IOCTL
case SIOCGCANBITRATE: /* Get bitrate from a CAN controller */
{
struct can_ioctl_data_s *req =
@ -1713,6 +1714,7 @@ static int s32k3xx_ioctl(struct net_driver_s *dev, int cmd,
}
}
break;
#endif
default:
ret = -ENOTTY;