Vyacheslav-S / mt7601u-AP

Orange Pi MT7601u Access Point and Station Mode support
2 stars 1 forks source link

unable to complie for kernel 6 make errors #1

Open KSMaan45 opened 8 months ago

KSMaan45 commented 8 months ago

Hey i manage to get ap mode working on my mt7601u card for debian 11.8.0 with kernel 5.10 (amd64), but for kernel 6 having following error on kde neon and arch linux:-

neon@neon:~/mt7601u-AP$ make -C /lib/modules/$(uname -r)/build M=$(pwd) modules
make: Entering directory '/usr/src/linux-headers-6.2.0-39-generic'
warning: the compiler differs from the one used to build the kernel
  The kernel was built by: x86_64-linux-gnu-gcc-11 (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
  You are using:           gcc-11 (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
  CC [M]  /home/neon/mt7601u-AP/main.o
/home/neon/mt7601u-AP/main.c:415:29: error: initialization of ‘void (*)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, u64)’ {aka ‘void (*)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, long long unsigned int)’} from incompatible pointer type ‘void (*)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, u32)’ {aka ‘void (*)(struct ieee80211_hw *, struct ieee80211_vif *, struct ieee80211_bss_conf *, unsigned int)’} [-Werror=incompatible-pointer-types]
  415 |         .bss_info_changed = mt7601u_bss_info_changed,
      |                             ^~~~~~~~~~~~~~~~~~~~~~~~
/home/neon/mt7601u-AP/main.c:415:29: note: (near initialization for ‘mt7601u_ops.bss_info_changed’)
/home/neon/mt7601u-AP/main.c:420:20: error: initialization of ‘int (*)(struct ieee80211_hw *, struct ieee80211_vif *, unsigned int,  u16,  const struct ieee80211_tx_queue_params *)’ {aka ‘int (*)(struct ieee80211_hw *, struct ieee80211_vif *, unsigned int,  short unsigned int,  const struct ieee80211_tx_queue_params *)’} from incompatible pointer type ‘int (*)(struct ieee80211_hw *, struct ieee80211_vif *, u16,  const struct ieee80211_tx_queue_params *)’ {aka ‘int (*)(struct ieee80211_hw *, struct ieee80211_vif *, short unsigned int,  const struct ieee80211_tx_queue_params *)’} [-Werror=incompatible-pointer-types]
  420 |         .conf_tx = mt7601u_conf_tx,
      |                    ^~~~~~~~~~~~~~~
/home/neon/mt7601u-AP/main.c:420:20: note: (near initialization for ‘mt7601u_ops.conf_tx’)
cc1: some warnings being treated as errors
make[1]: *** [scripts/Makefile.build:260: /home/neon/mt7601u-AP/main.o] Error 1
make: *** [Makefile:2026: /home/neon/mt7601u-AP] Error 2
make: Leaving directory '/usr/src/linux-headers-6.2.0-39-generic'
techatreyo commented 6 months ago

I am on 5.10.146 | ubanle to compile ?? ...???