mirror of
https://github.com/nxp-imx/mwifiex.git
synced 2024-11-14 11:05:34 +00:00
mxm_wifiex: fix the PDE_DATA build errors on L5.16 kernel
L5.16 kernel patch commit a1c11021f19cb0a80f removed the PDE_DATA() and replace it with pde_data(), so need to change accordingly, otherwise will have the driver build errors. Signed-off-by: Sherry Sun <sherry.sun@nxp.com> Approved-by: Tian Yang <yang.tian@nxp.com>
This commit is contained in:
parent
4f17224637
commit
b227e66e06
2 changed files with 24 additions and 8 deletions
|
@ -743,7 +743,9 @@ static int woal_histogram_read(struct seq_file *sfp, void *data)
|
|||
|
||||
static int woal_histogram_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_histogram_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_histogram_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_histogram_read, PDE(inode)->data);
|
||||
|
@ -942,7 +944,9 @@ static int woal_log_read(struct seq_file *sfp, void *data)
|
|||
*/
|
||||
static int woal_log_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_log_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_log_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_log_read, PDE(inode)->data);
|
||||
|
@ -1266,7 +1270,9 @@ static ssize_t woal_debug_write(struct file *f, const char __user *buf,
|
|||
|
||||
static int woal_debug_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_debug_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_debug_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_debug_read, PDE(inode)->data);
|
||||
|
|
|
@ -358,7 +358,9 @@ exit:
|
|||
|
||||
static int woal_info_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_info_proc_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_info_proc_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_info_proc_read, PDE(inode)->data);
|
||||
|
@ -776,7 +778,9 @@ static int woal_config_read(struct seq_file *sfp, void *data)
|
|||
|
||||
static int woal_config_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_config_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_config_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_config_read, PDE(inode)->data);
|
||||
|
@ -851,7 +855,9 @@ done:
|
|||
|
||||
static int woal_drv_dump_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_drv_dump_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_drv_dump_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_drv_dump_read, PDE(inode)->data);
|
||||
|
@ -928,7 +934,9 @@ done:
|
|||
|
||||
static int woal_fw_dump_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_fw_dump_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_fw_dump_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_fw_dump_read, PDE(inode)->data);
|
||||
|
@ -978,7 +986,9 @@ static int woal_wifi_status_read(struct seq_file *sfp, void *data)
|
|||
|
||||
static int woal_wifi_status_proc_open(struct inode *inode, struct file *file)
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 16, 0)
|
||||
return single_open(file, woal_wifi_status_read, pde_data(inode));
|
||||
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
|
||||
return single_open(file, woal_wifi_status_read, PDE_DATA(inode));
|
||||
#else
|
||||
return single_open(file, woal_wifi_status_read, PDE(inode)->data);
|
||||
|
|
Loading…
Reference in a new issue