From 9452a6e87b6c2c70513bc47a2470bf9f1168920e Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 13 Jun 2020 10:39:22 +0100 Subject: gentoo resync : 13.06.2020 --- net-wireless/broadcom-sta/Manifest | 3 +- .../broadcom-sta-6.30.223.271-r5.ebuild | 3 +- .../broadcom-sta-6.30.223.271-r5-linux-5.6.patch | 88 ++++++++++++++++++++++ 3 files changed, 92 insertions(+), 2 deletions(-) create mode 100644 net-wireless/broadcom-sta/files/broadcom-sta-6.30.223.271-r5-linux-5.6.patch (limited to 'net-wireless/broadcom-sta') diff --git a/net-wireless/broadcom-sta/Manifest b/net-wireless/broadcom-sta/Manifest index 284f66cca0ed..7fc2c9df90d5 100644 --- a/net-wireless/broadcom-sta/Manifest +++ b/net-wireless/broadcom-sta/Manifest @@ -10,8 +10,9 @@ AUX broadcom-sta-6.30.223.271-r4-linux-4.15.patch 1343 BLAKE2B ca87ae817cefd6436 AUX broadcom-sta-6.30.223.271-r4-linux-4.7.patch 3897 BLAKE2B ecf3eb75f8eb3331b0a36b39851536de43cffd3b303db9e9f4fe6fe55d463c3343aba17a99668448427764a719e15e3e862d6a3dc0bc61cb68da9934fb427c6f SHA512 f61ecfb6b8c5a377c7a4da7549c9ec75677782fa2f97e64de0df1259e0ec3b993cfa3eaa4ff50331703ee18ef28f2af0d09839dd3b63ed994e6b29cbfe8ed73f AUX broadcom-sta-6.30.223.271-r4-linux-4.8.patch 1835 BLAKE2B 7e091ac44616ea4cfa80b3a5563f4c6a235d2431b911f6bc52074a76b2c1d609dc546430f048abf042f862907f573c6b1dfa24c8c424aeefe73ff13ae3f34900 SHA512 e5959921b6f0cd5d61d7ed568f549b0920f394458c28257c05064b89d7067ce11c8e44ed0e5a48a65bd041c6193d9ae2d02fca2f5efbfb787d3f9001786a4578 AUX broadcom-sta-6.30.223.271-r5-linux-5.1.patch 829 BLAKE2B 7bb59009307d423e72832d14114b7e6bd016717ace260174b2b9dbc909ec7eb962aec88d930f34ee6c09165e937a2cc271eac7e6b214fe8161a8f76af1aaa83c SHA512 e8780fbff3ed0640b30b44ca777d56bdcf8b23702d4fa827c843919658f022090ca3e2533541f577e7b49133cb2bb3d6ec85bcc9c023a82bea892e231f01a550 +AUX broadcom-sta-6.30.223.271-r5-linux-5.6.patch 3056 BLAKE2B 3842420d177c7faf6ac86e00acd5365cb6499ad82071cf7e37f2b765463c945f9634e73126520934011ee63aefee51937d8ff0baa3b206fc5902f2b15fe151e0 SHA512 9edd068851acf534efa424e9b3b3157e75d029f799c1f3a383eb0a9678fee56d6c01817a055e2fa405bba0c25fa2db89b4665a30a9fd35d4e58056bf85cadabc DIST README-broadcom-sta-6.30.223.271.txt 17216 BLAKE2B af6db6e129911d1589d7d6cb7166bee32ce1ca98a4e5c9b3515a44e48681d8a7a7a6b697419b2bcd9c46f0f4ca1f7ece632b63531b4a4ecd91df4f9dddf043c9 SHA512 672ecc5afcd8535a9f8beb4baea5a40c584b7682844e9ff0e4f66b7406b42118a99dce1fcd580118187fdc506781334b8243082def2b78dce916d90c55ab3663 DIST hybrid-v35-nodebug-pcoem-6_30_223_271.tar.gz 2869247 BLAKE2B 2e3189c468cec50b1a980452a4b2bd0f9657d9adf6fae2a95a8b1c2d1df2f5f6beb4cb903f72f444eddf823fe4375299864cd62191c9d59c4f77598b5d3aa246 SHA512 0361ba30d97bcb1dedf46c11ef1b9a16f09cde3faa6be87b3ccc28679f34183c2fdf511e7c3b5c26b304f6961da454ccf71844b92bbb2f25aa876249496a2f1b DIST hybrid-v35_64-nodebug-pcoem-6_30_223_271.tar.gz 2928541 BLAKE2B e9d01c1a1a63c07f720e3ee53ee3ef634ab12694135300cb0ce47ade0e9e0084967a0b6df64d983e8184240eb3defb128f650bddb7727e901d50315307f3398a SHA512 6855781f7c69a9aecb9461932423688964879d5a4df571f01ae7adaa7bf21a410bef839605d555afb6c8f4eec92fe8510af6cb120930095617ff6cdcccedaf17 -EBUILD broadcom-sta-6.30.223.271-r5.ebuild 3763 BLAKE2B 923c9cf82aa607b7a980c2e8608cdba9ba7c2f1ed76da5f16f648e7a2f6e35e29d32c5264999c78c14b5984aed5bdfd6616d5d17b9988de61740cb443a880281 SHA512 b11a485700e3efb06c310a3b296414dce84ce248db166f8efb04254128e7efc5132ecdf4adcf11cb5c254701f590812a850de7d4c8aa0bca79284eeb514afd55 +EBUILD broadcom-sta-6.30.223.271-r5.ebuild 3817 BLAKE2B 4817e0b2188686ba4af9982cfa269898348f25a2d18f1f8547f929fb94f52ae60b95a9fb3e3316500bdf8a5f5556c3ae818b4e5c3a15e87e56292cdfc1150014 SHA512 936c80d538fa007c564a268d2db37cd982c287e5c7be6b31ce4895e38d4cfb5b573750d1b0f0f93a6ebceda19991ff983aef17f5c503d9d8e4be4dfbee93a9e5 MISC metadata.xml 249 BLAKE2B 4a3b51bf90b3ec35dd72dca3b3c73fb89d3e3d08c0989cd7939205ae9d655200886882c2de26146caac3f42ff06ab4a898b85325bd80e69f39491bf4c34ae89e SHA512 4211cb5a85b6a437c0d1727891123af70f296e685c9d59ead2032abbe19d3828fb83d59e559056455ad8b9aadd6136141ab7f9edaff2d55ce2d86b1d698722ce diff --git a/net-wireless/broadcom-sta/broadcom-sta-6.30.223.271-r5.ebuild b/net-wireless/broadcom-sta/broadcom-sta-6.30.223.271-r5.ebuild index 91581b52a4e4..b84669a99696 100644 --- a/net-wireless/broadcom-sta/broadcom-sta-6.30.223.271-r5.ebuild +++ b/net-wireless/broadcom-sta/broadcom-sta-6.30.223.271-r5.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -84,6 +84,7 @@ PATCHES=( "${FILESDIR}/${PN}-6.30.223.271-r4-linux-4.12.patch" "${FILESDIR}/${PN}-6.30.223.271-r4-linux-4.15.patch" "${FILESDIR}/${PN}-6.30.223.271-r5-linux-5.1.patch" + "${FILESDIR}/${PN}-6.30.223.271-r5-linux-5.6.patch" ) src_install() { diff --git a/net-wireless/broadcom-sta/files/broadcom-sta-6.30.223.271-r5-linux-5.6.patch b/net-wireless/broadcom-sta/files/broadcom-sta-6.30.223.271-r5-linux-5.6.patch new file mode 100644 index 000000000000..71264346f86e --- /dev/null +++ b/net-wireless/broadcom-sta/files/broadcom-sta-6.30.223.271-r5-linux-5.6.patch @@ -0,0 +1,88 @@ +From: Herman van Hazendonk +Date: Tue, 31 Mar 2020 17:09:55 +0200 +Subject: [PATCH] Add fixes for 5.6 kernel +Origin: https://salsa.debian.org/Herrie82-guest/broadcom-sta/-/merge_requests/1 + +Use ioremap instead of ioremap_nocache and proc_ops instead of +file_operations on Linux kernel 5.6 and above. + + Patch amended to adapt i386 arch. +--- + src/shared/linux_osl.c | 6 +++++- + src/wl/sys/wl_linux.c | 21 ++++++++++++++++++++- + 2 files changed, 25 insertions(+), 2 deletions(-) + +diff --git a/src/shared/linux_osl.c b/src/shared/linux_osl.c +index b24a973..9bce9b1 100644 +--- a/src/shared/linux_osl.c ++++ b/src/shared/linux_osl.c +@@ -946,7 +946,11 @@ osl_getcycles(void) + void * + osl_reg_map(uint32 pa, uint size) + { +- return (ioremap_nocache((unsigned long)pa, (unsigned long)size)); ++ #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) ++ return (ioremap((unsigned long)pa, (unsigned long)size)); ++ #else ++ return (ioremap_nocache((unsigned long)pa, (unsigned long)size)); ++ #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) */ + } + + void +diff --git a/src/wl/sys/wl_linux.c b/src/wl/sys/wl_linux.c +index ab7b883..10621c2 100644 +--- a/src/wl/sys/wl_linux.c ++++ b/src/wl/sys/wl_linux.c +@@ -590,10 +590,17 @@ wl_attach(uint16 vendor, uint16 device, ulong regs, + } + wl->bcm_bustype = bustype; + ++ #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) ++ if ((wl->regsva = ioremap(dev->base_addr, PCI_BAR0_WINSZ)) == NULL) { ++ WL_ERROR(("wl%d: ioremap() failed\n", unit)); ++ goto fail; ++ } ++ #else + if ((wl->regsva = ioremap_nocache(dev->base_addr, PCI_BAR0_WINSZ)) == NULL) { + WL_ERROR(("wl%d: ioremap() failed\n", unit)); + goto fail; + } ++ #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) */ + + wl->bar1_addr = bar1_addr; + wl->bar1_size = bar1_size; +@@ -780,8 +787,13 @@ wl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) + if ((val & 0x0000ff00) != 0) + pci_write_config_dword(pdev, 0x40, val & 0xffff00ff); + bar1_size = pci_resource_len(pdev, 2); ++ #if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) ++ bar1_addr = (uchar *)ioremap(pci_resource_start(pdev, 2), ++ bar1_size); ++ #else + bar1_addr = (uchar *)ioremap_nocache(pci_resource_start(pdev, 2), + bar1_size); ++ #endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) */ + wl = wl_attach(pdev->vendor, pdev->device, pci_resource_start(pdev, 0), PCI_BUS, pdev, + pdev->irq, bar1_addr, bar1_size); + +@@ -3354,12 +3366,19 @@ wl_proc_write(struct file *filp, const char __user *buff, size_t length, loff_t + } + + #if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0) ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) ++static const struct proc_ops wl_fops = { ++ .proc_read = wl_proc_read, ++ .proc_write = wl_proc_write, ++}; ++#else + static const struct file_operations wl_fops = { + .owner = THIS_MODULE, + .read = wl_proc_read, + .write = wl_proc_write, + }; +-#endif ++#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0) */ ++#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0) */ + + static int + wl_reg_proc_entry(wl_info_t *wl) -- cgit v1.2.3