From: Greg Kroah-Hartman Date: Mon, 11 Dec 2023 08:10:42 +0000 (+0100) Subject: Merge 6.7-rc5 into tty-next X-Git-Url: https://repo.jachan.dev/J-linux.git/commitdiff_plain/e045e18dbf3eaac32cdeb2799a5ec84fa694636c?hp=-c Merge 6.7-rc5 into tty-next We need the serial fixes in here as well to build off of. Signed-off-by: Greg Kroah-Hartman --- e045e18dbf3eaac32cdeb2799a5ec84fa694636c diff --combined MAINTAINERS index d60009f3ef9c,e2c6187a3ac8..e8634f8bd561 --- a/MAINTAINERS +++ b/MAINTAINERS @@@ -171,13 -171,10 +171,10 @@@ S: Supporte F: drivers/soc/fujitsu/a64fx-diag.c A8293 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/a8293* AACRAID SCSI RAID DRIVER @@@ -576,23 -573,17 +573,17 @@@ F: drivers/iio/accel/adxl372_i2c. F: drivers/iio/accel/adxl372_spi.c AF9013 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/af9013* AF9033 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/af9033* AFFS FILE SYSTEM @@@ -650,13 -641,10 +641,10 @@@ F: fs/aio. F: include/linux/*aio*.h AIRSPY MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/airspy/ ALACRITECH GIGABIT ETHERNET DRIVER @@@ -2155,6 -2143,7 +2143,7 @@@ S: Maintaine T: git git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux.git F: arch/arm/boot/dts/nxp/imx/ F: arch/arm/boot/dts/nxp/mxs/ + F: arch/arm64/boot/dts/freescale/ X: arch/arm64/boot/dts/freescale/fsl-* X: arch/arm64/boot/dts/freescale/qoriq-* X: drivers/media/i2c/ @@@ -2535,7 -2524,7 +2524,7 @@@ F: drivers/*/*/*wpcm F: drivers/*/*wpcm* ARM/NXP S32G ARCHITECTURE - M: Chester Lin + M: Chester Lin R: Andreas Färber R: Matthias Brugger R: NXP S32 Linux Team @@@ -5076,7 -5065,6 +5065,6 @@@ CLANG CONTROL FLOW INTEGRITY SUPPOR M: Sami Tolvanen M: Kees Cook R: Nathan Chancellor - R: Nick Desaulniers L: llvm@lists.linux.dev S: Supported B: https://github.com/ClangBuiltLinux/linux/issues @@@ -5091,8 -5079,9 +5079,9 @@@ F: .clang-forma CLANG/LLVM BUILD SUPPORT M: Nathan Chancellor - M: Nick Desaulniers - R: Tom Rix + R: Nick Desaulniers + R: Bill Wendling + R: Justin Stitt L: llvm@lists.linux.dev S: Supported W: https://clangbuiltlinux.github.io/ @@@ -5242,7 -5231,6 +5231,6 @@@ F: drivers/platform/x86/compal-laptop. COMPILER ATTRIBUTES M: Miguel Ojeda - R: Nick Desaulniers S: Maintained F: include/linux/compiler_attributes.h @@@ -5605,13 -5593,10 +5593,10 @@@ F: Documentation/driver-api/media/drive F: drivers/media/pci/cx88/ CXD2820R MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/cxd2820r* CXGB3 ETHERNET DRIVER (CXGB3) @@@ -5724,13 -5709,10 +5709,10 @@@ F: Documentation/devicetree/bindings/in F: drivers/input/keyboard/cypress-sf.c CYPRESS_FIRMWARE MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/common/cypress_firmware* CYTTSP TOUCHSCREEN DRIVER @@@ -7320,53 -7302,38 +7302,38 @@@ T: git git://linuxtv.org/media_tree.gi F: drivers/media/pci/dt3155/ DVB_USB_AF9015 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/af9015* DVB_USB_AF9035 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/af9035* DVB_USB_ANYSEE MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/anysee* DVB_USB_AU6610 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/au6610* DVB_USB_CE6230 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/ce6230* DVB_USB_CXUSB MEDIA DRIVER @@@ -7380,22 -7347,17 +7347,17 @@@ T: git git://linuxtv.org/media_tree.gi F: drivers/media/usb/dvb-usb/cxusb* DVB_USB_EC168 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/ec168* DVB_USB_GL861 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/gl861* DVB_USB_MXL111SF MEDIA DRIVER @@@ -7409,23 -7371,18 +7371,18 @@@ T: git git://linuxtv.org/mkrufky/mxl111 F: drivers/media/usb/dvb-usb-v2/mxl111sf* DVB_USB_RTL28XXU MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/rtl28xxu* DVB_USB_V2 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/dvb-usb-v2/dvb_usb* F: drivers/media/usb/dvb-usb-v2/usb_urb.c @@@ -7467,13 -7424,10 +7424,10 @@@ F: Documentation/devicetree/bindings/in F: drivers/input/misc/e3x0-button.c E4000 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/e4000* EARTH_PT1 MEDIA DRIVER @@@ -7489,13 -7443,10 +7443,10 @@@ S: Odd Fixe F: drivers/media/pci/pt3/ EC100 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/ec100* ECRYPT FILE SYSTEM @@@ -7855,6 -7806,7 +7806,7 @@@ R: Yue Hu L: linux-erofs@lists.ozlabs.org S: Maintained + W: https://erofs.docs.kernel.org T: git git://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs.git F: Documentation/ABI/testing/sysfs-fs-erofs F: Documentation/filesystems/erofs.rst @@@ -8112,13 -8064,10 +8064,10 @@@ F: drivers/media/tuners/fc0011. F: drivers/media/tuners/fc0011.h FC2580 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/fc2580* FCOE SUBSYSTEM (libfc, libfcoe, fcoe) @@@ -9248,13 -9197,10 +9197,10 @@@ F: include/trace/events/habanalabs. F: include/uapi/drm/habanalabs_accel.h HACKRF MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/hackrf/ HANDSHAKE UPCALL FOR TRANSPORT LAYER SECURITY @@@ -9627,6 -9573,7 +9573,7 @@@ F: drivers/crypto/hisilicon/sgl. F: include/linux/hisi_acc_qm.h HISILICON ROCE DRIVER + M: Chengchang Tang M: Junxian Huang L: linux-rdma@vger.kernel.org S: Maintained @@@ -11024,7 -10971,6 +10971,6 @@@ F: drivers/net/wireless/intel/iwlwifi INTEL WMI SLIM BOOTLOADER (SBL) FIRMWARE UPDATE DRIVER M: Jithu Joseph - R: Maurice Ma S: Maintained W: https://slimbootloader.github.io/security/firmware-update.html F: drivers/platform/x86/intel/wmi/sbl-fw-update.c @@@ -11328,13 -11274,10 +11274,10 @@@ F: Documentation/hwmon/it87.rs F: drivers/hwmon/it87.c IT913X MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/it913x* ITE IT66121 HDMI BRIDGE DRIVER @@@ -11516,7 -11459,6 +11459,6 @@@ F: fs/autofs KERNEL BUILD + files below scripts/ (unless maintained elsewhere) M: Masahiro Yamada R: Nathan Chancellor - R: Nick Desaulniers R: Nicolas Schier L: linux-kbuild@vger.kernel.org S: Maintained @@@ -12208,6 -12150,13 +12150,13 @@@ F: include/linux/nd. F: include/uapi/linux/ndctl.h F: tools/testing/nvdimm/ + LIBRARY CODE + M: Andrew Morton + L: linux-kernel@vger.kernel.org + S: Supported + T: git git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-nonmm-unstable + F: lib/* + LICENSES and SPDX stuff M: Thomas Gleixner M: Greg Kroah-Hartman @@@ -12687,13 -12636,10 +12636,10 @@@ W: http://www.tazenda.demon.co.uk/phil/ F: arch/m68k/hp300/ M88DS3103 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/m88ds3103* M88RS2000 MEDIA DRIVER @@@ -13778,7 -13724,6 +13724,6 @@@ F: drivers/net/ethernet/mellanox/mlxfw MELLANOX HARDWARE PLATFORM SUPPORT M: Hans de Goede M: Ilpo Järvinen - M: Mark Gross M: Vadim Pasternak L: platform-driver-x86@vger.kernel.org S: Supported @@@ -14387,7 -14332,6 +14332,6 @@@ F: drivers/platform/surface/surface_gpe MICROSOFT SURFACE HARDWARE PLATFORM SUPPORT M: Hans de Goede M: Ilpo Järvinen - M: Mark Gross M: Maximilian Luz L: platform-driver-x86@vger.kernel.org S: Maintained @@@ -14589,20 -14533,16 +14533,16 @@@ F: include/asm-generic/tlb. F: mm/mmu_gather.c MN88472 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ F: drivers/media/dvb-frontends/mn88472* MN88473 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ F: drivers/media/dvb-frontends/mn88473* @@@ -14690,23 -14630,17 +14630,17 @@@ S: Orpha F: drivers/platform/x86/msi-wmi.c MSI001 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/msi001* MSI2500 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/usb/msi2500/ MSTAR INTERRUPT CONTROLLER DRIVER @@@ -14994,6 -14928,7 +14928,7 @@@ M: Jakub Kicinski L: netdev@vger.kernel.org S: Maintained + P: Documentation/process/maintainer-netdev.rst Q: https://patchwork.kernel.org/project/netdevbpf/list/ T: git git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git T: git git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git @@@ -15045,6 -14980,7 +14980,7 @@@ M: Jakub Kicinski L: netdev@vger.kernel.org S: Maintained + P: Documentation/process/maintainer-netdev.rst Q: https://patchwork.kernel.org/project/netdevbpf/list/ B: mailto:netdev@vger.kernel.org T: git git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git @@@ -15055,6 -14991,7 +14991,7 @@@ F: Documentation/networking F: Documentation/process/maintainer-netdev.rst F: Documentation/userspace-api/netlink/ F: include/linux/in.h + F: include/linux/indirect_call_wrapper.h F: include/linux/net.h F: include/linux/netdevice.h F: include/net/ @@@ -15067,6 -15004,7 +15004,7 @@@ F: lib/random32. F: net/ F: tools/net/ F: tools/testing/selftests/net/ + X: net/9p/ X: net/bluetooth/ NETWORKING [IPSEC] @@@ -17774,13 -17712,10 +17712,10 @@@ F: drivers/bus/fsl-mc F: include/uapi/linux/fsl_mc.h QT1010 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/qt1010* QUALCOMM ATH12K WIRELESS DRIVER @@@ -17947,6 -17882,8 +17882,8 @@@ L: iommu@lists.linux.de L: linux-arm-msm@vger.kernel.org S: Maintained F: drivers/iommu/arm/arm-smmu/qcom_iommu.c + F: drivers/iommu/arm/arm-smmu/arm-smmu-qcom* + F: drivers/iommu/msm_iommu* QUALCOMM IPC ROUTER (QRTR) DRIVER M: Manivannan Sadhasivam @@@ -18833,33 -18770,24 +18770,24 @@@ S: Maintaine F: drivers/tty/rpmsg_tty.c RTL2830 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/rtl2830* RTL2832 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/rtl2832* RTL2832_SDR MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/rtl2832_sdr* RTL8180 WIRELESS DRIVER @@@ -19669,13 -19597,10 +19597,10 @@@ F: drivers/media/platform/renesas/sh_vo F: include/media/drv-intf/sh_vou.h SI2157 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/si2157* SI2165 MEDIA DRIVER @@@ -19687,13 -19612,10 +19612,10 @@@ Q: http://patchwork.linuxtv.org/project F: drivers/media/dvb-frontends/si2165* SI2168 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/si2168* SI470X FM RADIO RECEIVER I2C DRIVER @@@ -21195,33 -21117,24 +21117,24 @@@ W: http://tcp-lp-mod.sourceforge.net F: net/ipv4/tcp_lp.c TDA10071 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/dvb-frontends/tda10071* TDA18212 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/tda18212* TDA18218 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/tda18218* TDA18250 MEDIA DRIVER @@@ -22078,6 -21991,7 +21991,7 @@@ F: drivers/watchdog/tqmx86_wdt. TRACING M: Steven Rostedt M: Masami Hiramatsu + R: Mathieu Desnoyers L: linux-kernel@vger.kernel.org L: linux-trace-kernel@vger.kernel.org S: Maintained @@@ -22156,13 -22070,10 +22070,10 @@@ F: include/uapi/linux/serial_core. F: include/uapi/linux/tty.h TUA9001 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org - W: http://palosaari.fi/linux/ Q: http://patchwork.linuxtv.org/project/linux-media/list/ - T: git git://linuxtv.org/anttip/media_tree.git F: drivers/media/tuners/tua9001* TULIP NETWORK DRIVERS @@@ -23018,6 -22929,7 +22929,6 @@@ M: Amit Shah M: Ilpo Järvinen - M: Mark Gross L: platform-driver-x86@vger.kernel.org S: Maintained Q: https://patchwork.kernel.org/project/platform-driver-x86/list/ @@@ -24107,20 -24018,16 +24017,16 @@@ S: Orpha F: drivers/net/wireless/zydas/zd1211rw/ ZD1301 MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org/ - W: http://palosaari.fi/linux/ Q: https://patchwork.linuxtv.org/project/linux-media/list/ F: drivers/media/usb/dvb-usb-v2/zd1301* ZD1301_DEMOD MEDIA DRIVER - M: Antti Palosaari L: linux-media@vger.kernel.org - S: Maintained + S: Orphan W: https://linuxtv.org/ - W: http://palosaari.fi/linux/ Q: https://patchwork.linuxtv.org/project/linux-media/list/ F: drivers/media/dvb-frontends/zd1301_demod* diff --combined drivers/platform/surface/aggregator/core.c index 72d7314a4efd,6152be38398c..9591a28bc38a --- a/drivers/platform/surface/aggregator/core.c +++ b/drivers/platform/surface/aggregator/core.c @@@ -227,13 -227,16 +227,16 @@@ EXPORT_SYMBOL_GPL(ssam_client_bind) /* -- Glue layer (serdev_device -> ssam_controller). ------------------------ */ -static int ssam_receive_buf(struct serdev_device *dev, const unsigned char *buf, - size_t n) +static ssize_t ssam_receive_buf(struct serdev_device *dev, const u8 *buf, + size_t n) { struct ssam_controller *ctrl; + int ret; ctrl = serdev_device_get_drvdata(dev); - return ssam_controller_receive_buf(ctrl, buf, n); + ret = ssam_controller_receive_buf(ctrl, buf, n); + + return ret < 0 ? 0 : ret; } static void ssam_write_wakeup(struct serdev_device *dev) diff --combined drivers/tty/serial/8250/8250_dw.c index 63b14ce9c009,e6218766d0c8..2d1f350a4bea --- a/drivers/tty/serial/8250/8250_dw.c +++ b/drivers/tty/serial/8250/8250_dw.c @@@ -663,7 -663,7 +663,7 @@@ static int dw8250_probe(struct platform return 0; } -static int dw8250_remove(struct platform_device *pdev) +static void dw8250_remove(struct platform_device *pdev) { struct dw8250_data *data = platform_get_drvdata(pdev); struct device *dev = &pdev->dev; @@@ -680,6 -680,8 +680,6 @@@ pm_runtime_disable(dev); pm_runtime_put_noidle(dev); - - return 0; } static int dw8250_suspend(struct device *dev) @@@ -775,6 -777,7 +775,7 @@@ static const struct acpi_device_id dw82 { "INT33C5", (kernel_ulong_t)&dw8250_dw_apb }, { "INT3434", (kernel_ulong_t)&dw8250_dw_apb }, { "INT3435", (kernel_ulong_t)&dw8250_dw_apb }, + { "INTC10EE", (kernel_ulong_t)&dw8250_dw_apb }, { }, }; MODULE_DEVICE_TABLE(acpi, dw8250_acpi_match); @@@ -787,7 -790,7 +788,7 @@@ static struct platform_driver dw8250_pl .acpi_match_table = dw8250_acpi_match, }, .probe = dw8250_probe, - .remove = dw8250_remove, + .remove_new = dw8250_remove, }; module_platform_driver(dw8250_platform_driver); diff --combined drivers/tty/serial/8250/8250_omap.c index 5a89a8cd7f71,578f35895b27..6942990a333c --- a/drivers/tty/serial/8250/8250_omap.c +++ b/drivers/tty/serial/8250/8250_omap.c @@@ -933,7 -933,7 +933,7 @@@ static void __dma_rx_do_complete(struc if (priv->habit & UART_HAS_RHR_IT_DIS) { reg = serial_in(p, UART_OMAP_IER2); reg &= ~UART_OMAP_IER2_RHR_IT_DIS; - serial_out(p, UART_OMAP_IER2, UART_OMAP_IER2_RHR_IT_DIS); + serial_out(p, UART_OMAP_IER2, reg); } dmaengine_tx_status(rxchan, cookie, &state); @@@ -1079,7 -1079,7 +1079,7 @@@ static int omap_8250_rx_dma(struct uart if (priv->habit & UART_HAS_RHR_IT_DIS) { reg = serial_in(p, UART_OMAP_IER2); reg |= UART_OMAP_IER2_RHR_IT_DIS; - serial_out(p, UART_OMAP_IER2, UART_OMAP_IER2_RHR_IT_DIS); + serial_out(p, UART_OMAP_IER2, reg); } dma_async_issue_pending(dma->rxchan); @@@ -1298,10 -1298,12 +1298,12 @@@ static int omap_8250_dma_handle_irq(str status = serial_port_in(port, UART_LSR); - if (priv->habit & UART_HAS_EFR2) - am654_8250_handle_rx_dma(up, iir, status); - else - status = omap_8250_handle_rx_dma(up, iir, status); + if ((iir & 0x3f) != UART_IIR_THRI) { + if (priv->habit & UART_HAS_EFR2) + am654_8250_handle_rx_dma(up, iir, status); + else + status = omap_8250_handle_rx_dma(up, iir, status); + } serial8250_modem_status(up); if (status & UART_LSR_THRE && up->dma->tx_err) { @@@ -1584,7 -1586,7 +1586,7 @@@ err return ret; } -static int omap8250_remove(struct platform_device *pdev) +static void omap8250_remove(struct platform_device *pdev) { struct omap8250_priv *priv = platform_get_drvdata(pdev); struct uart_8250_port *up; @@@ -1592,7 -1594,7 +1594,7 @@@ err = pm_runtime_resume_and_get(&pdev->dev); if (err) - return err; + dev_err(&pdev->dev, "Failed to resume hardware\n"); up = serial8250_get_port(priv->line); omap_8250_shutdown(&up->port); @@@ -1604,6 -1606,7 +1606,6 @@@ pm_runtime_disable(&pdev->dev); cpu_latency_qos_remove_request(&priv->pm_qos_request); device_init_wakeup(&pdev->dev, false); - return 0; } static int omap8250_prepare(struct device *dev) @@@ -1862,7 -1865,7 +1864,7 @@@ static struct platform_driver omap8250_ .of_match_table = omap8250_dt_ids, }, .probe = omap8250_probe, - .remove = omap8250_remove, + .remove_new = omap8250_remove, }; module_platform_driver(omap8250_platform_driver); diff --combined drivers/tty/serial/amba-pl011.c index bb475c1642fc,b7635363373e..5521e36147a0 --- a/drivers/tty/serial/amba-pl011.c +++ b/drivers/tty/serial/amba-pl011.c @@@ -218,17 -218,18 +218,18 @@@ static struct vendor_data vendor_st = /* Deals with DMA transactions */ - struct pl011_sgbuf { - struct scatterlist sg; - char *buf; + struct pl011_dmabuf { + dma_addr_t dma; + size_t len; + char *buf; }; struct pl011_dmarx_data { struct dma_chan *chan; struct completion complete; bool use_buf_b; - struct pl011_sgbuf sgbuf_a; - struct pl011_sgbuf sgbuf_b; + struct pl011_dmabuf dbuf_a; + struct pl011_dmabuf dbuf_b; dma_cookie_t cookie; bool running; struct timer_list timer; @@@ -241,7 -242,8 +242,8 @@@ struct pl011_dmatx_data { struct dma_chan *chan; - struct scatterlist sg; + dma_addr_t dma; + size_t len; char *buf; bool queued; }; @@@ -366,32 -368,24 +368,24 @@@ static int pl011_fifo_to_tty(struct uar #define PL011_DMA_BUFFER_SIZE PAGE_SIZE - static int pl011_sgbuf_init(struct dma_chan *chan, struct pl011_sgbuf *sg, + static int pl011_dmabuf_init(struct dma_chan *chan, struct pl011_dmabuf *db, enum dma_data_direction dir) { - dma_addr_t dma_addr; - - sg->buf = dma_alloc_coherent(chan->device->dev, - PL011_DMA_BUFFER_SIZE, &dma_addr, GFP_KERNEL); - if (!sg->buf) + db->buf = dma_alloc_coherent(chan->device->dev, PL011_DMA_BUFFER_SIZE, + &db->dma, GFP_KERNEL); + if (!db->buf) return -ENOMEM; - - sg_init_table(&sg->sg, 1); - sg_set_page(&sg->sg, phys_to_page(dma_addr), - PL011_DMA_BUFFER_SIZE, offset_in_page(dma_addr)); - sg_dma_address(&sg->sg) = dma_addr; - sg_dma_len(&sg->sg) = PL011_DMA_BUFFER_SIZE; + db->len = PL011_DMA_BUFFER_SIZE; return 0; } - static void pl011_sgbuf_free(struct dma_chan *chan, struct pl011_sgbuf *sg, + static void pl011_dmabuf_free(struct dma_chan *chan, struct pl011_dmabuf *db, enum dma_data_direction dir) { - if (sg->buf) { + if (db->buf) { dma_free_coherent(chan->device->dev, - PL011_DMA_BUFFER_SIZE, sg->buf, - sg_dma_address(&sg->sg)); + PL011_DMA_BUFFER_SIZE, db->buf, db->dma); } } @@@ -444,9 -438,9 +438,9 @@@ static void pl011_dma_probe(struct uart dma_chan_name(uap->dmatx.chan)); /* Optionally make use of an RX channel as well */ - chan = dma_request_slave_channel(dev, "rx"); + chan = dma_request_chan(dev, "rx"); - if (!chan && plat && plat->dma_rx_param) { + if (IS_ERR(chan) && plat && plat->dma_rx_param) { chan = dma_request_channel(mask, plat->dma_filter, plat->dma_rx_param); if (!chan) { @@@ -455,7 -449,7 +449,7 @@@ } } - if (chan) { + if (!IS_ERR(chan)) { struct dma_slave_config rx_conf = { .src_addr = uap->port.mapbase + pl011_reg_to_offset(uap, REG_DR), @@@ -552,8 -546,8 +546,8 @@@ static void pl011_dma_tx_callback(void uart_port_lock_irqsave(&uap->port, &flags); if (uap->dmatx.queued) - dma_unmap_sg(dmatx->chan->device->dev, &dmatx->sg, 1, - DMA_TO_DEVICE); + dma_unmap_single(dmatx->chan->device->dev, dmatx->dma, + dmatx->len, DMA_TO_DEVICE); dmacr = uap->dmacr; uap->dmacr = dmacr & ~UART011_TXDMAE; @@@ -639,18 -633,19 +633,19 @@@ static int pl011_dma_tx_refill(struct u memcpy(&dmatx->buf[first], &xmit->buf[0], second); } - dmatx->sg.length = count; - - if (dma_map_sg(dma_dev->dev, &dmatx->sg, 1, DMA_TO_DEVICE) != 1) { + dmatx->len = count; + dmatx->dma = dma_map_single(dma_dev->dev, dmatx->buf, count, + DMA_TO_DEVICE); + if (dmatx->dma == DMA_MAPPING_ERROR) { uap->dmatx.queued = false; dev_dbg(uap->port.dev, "unable to map TX DMA\n"); return -EBUSY; } - desc = dmaengine_prep_slave_sg(chan, &dmatx->sg, 1, DMA_MEM_TO_DEV, + desc = dmaengine_prep_slave_single(chan, dmatx->dma, dmatx->len, DMA_MEM_TO_DEV, DMA_PREP_INTERRUPT | DMA_CTRL_ACK); if (!desc) { - dma_unmap_sg(dma_dev->dev, &dmatx->sg, 1, DMA_TO_DEVICE); + dma_unmap_single(dma_dev->dev, dmatx->dma, dmatx->len, DMA_TO_DEVICE); uap->dmatx.queued = false; /* * If DMA cannot be used right now, we complete this @@@ -813,8 -808,8 +808,8 @@@ __acquires(&uap->port.lock dmaengine_terminate_async(uap->dmatx.chan); if (uap->dmatx.queued) { - dma_unmap_sg(uap->dmatx.chan->device->dev, &uap->dmatx.sg, 1, - DMA_TO_DEVICE); + dma_unmap_single(uap->dmatx.chan->device->dev, uap->dmatx.dma, + uap->dmatx.len, DMA_TO_DEVICE); uap->dmatx.queued = false; uap->dmacr &= ~UART011_TXDMAE; pl011_write(uap->dmacr, uap, REG_DMACR); @@@ -828,15 -823,15 +823,15 @@@ static int pl011_dma_rx_trigger_dma(str struct dma_chan *rxchan = uap->dmarx.chan; struct pl011_dmarx_data *dmarx = &uap->dmarx; struct dma_async_tx_descriptor *desc; - struct pl011_sgbuf *sgbuf; + struct pl011_dmabuf *dbuf; if (!rxchan) return -EIO; /* Start the RX DMA job */ - sgbuf = uap->dmarx.use_buf_b ? - &uap->dmarx.sgbuf_b : &uap->dmarx.sgbuf_a; - desc = dmaengine_prep_slave_sg(rxchan, &sgbuf->sg, 1, + dbuf = uap->dmarx.use_buf_b ? + &uap->dmarx.dbuf_b : &uap->dmarx.dbuf_a; + desc = dmaengine_prep_slave_single(rxchan, dbuf->dma, dbuf->len, DMA_DEV_TO_MEM, DMA_PREP_INTERRUPT | DMA_CTRL_ACK); /* @@@ -876,8 -871,8 +871,8 @@@ static void pl011_dma_rx_chars(struct u bool readfifo) { struct tty_port *port = &uap->port.state->port; - struct pl011_sgbuf *sgbuf = use_buf_b ? - &uap->dmarx.sgbuf_b : &uap->dmarx.sgbuf_a; + struct pl011_dmabuf *dbuf = use_buf_b ? + &uap->dmarx.dbuf_b : &uap->dmarx.dbuf_a; int dma_count = 0; u32 fifotaken = 0; /* only used for vdbg() */ @@@ -886,7 -881,7 +881,7 @@@ if (uap->dmarx.poll_rate) { /* The data can be taken by polling */ - dmataken = sgbuf->sg.length - dmarx->last_residue; + dmataken = dbuf->len - dmarx->last_residue; /* Recalculate the pending size */ if (pending >= dmataken) pending -= dmataken; @@@ -900,7 -895,7 +895,7 @@@ * Note that tty_insert_flip_buf() tries to take as many chars * as it can. */ - dma_count = tty_insert_flip_string(port, sgbuf->buf + dmataken, + dma_count = tty_insert_flip_string(port, dbuf->buf + dmataken, pending); uap->port.icount.rx += dma_count; @@@ -911,7 -906,7 +906,7 @@@ /* Reset the last_residue for Rx DMA poll */ if (uap->dmarx.poll_rate) - dmarx->last_residue = sgbuf->sg.length; + dmarx->last_residue = dbuf->len; /* * Only continue with trying to read the FIFO if all DMA chars have @@@ -946,8 -941,8 +941,8 @@@ static void pl011_dma_rx_irq(struct uar { struct pl011_dmarx_data *dmarx = &uap->dmarx; struct dma_chan *rxchan = dmarx->chan; - struct pl011_sgbuf *sgbuf = dmarx->use_buf_b ? - &dmarx->sgbuf_b : &dmarx->sgbuf_a; + struct pl011_dmabuf *dbuf = dmarx->use_buf_b ? + &dmarx->dbuf_b : &dmarx->dbuf_a; size_t pending; struct dma_tx_state state; enum dma_status dmastat; @@@ -969,7 -964,7 +964,7 @@@ pl011_write(uap->dmacr, uap, REG_DMACR); uap->dmarx.running = false; - pending = sgbuf->sg.length - state.residue; + pending = dbuf->len - state.residue; BUG_ON(pending > PL011_DMA_BUFFER_SIZE); /* Then we terminate the transfer - we now know our residue */ dmaengine_terminate_all(rxchan); @@@ -996,8 -991,8 +991,8 @@@ static void pl011_dma_rx_callback(void struct pl011_dmarx_data *dmarx = &uap->dmarx; struct dma_chan *rxchan = dmarx->chan; bool lastbuf = dmarx->use_buf_b; - struct pl011_sgbuf *sgbuf = dmarx->use_buf_b ? - &dmarx->sgbuf_b : &dmarx->sgbuf_a; + struct pl011_dmabuf *dbuf = dmarx->use_buf_b ? + &dmarx->dbuf_b : &dmarx->dbuf_a; size_t pending; struct dma_tx_state state; int ret; @@@ -1015,7 -1010,7 +1010,7 @@@ * the DMA irq handler. So we check the residue here. */ rxchan->device->device_tx_status(rxchan, dmarx->cookie, &state); - pending = sgbuf->sg.length - state.residue; + pending = dbuf->len - state.residue; BUG_ON(pending > PL011_DMA_BUFFER_SIZE); /* Then we terminate the transfer - we now know our residue */ dmaengine_terminate_all(rxchan); @@@ -1067,16 -1062,16 +1062,16 @@@ static void pl011_dma_rx_poll(struct ti unsigned long flags; unsigned int dmataken = 0; unsigned int size = 0; - struct pl011_sgbuf *sgbuf; + struct pl011_dmabuf *dbuf; int dma_count; struct dma_tx_state state; - sgbuf = dmarx->use_buf_b ? &uap->dmarx.sgbuf_b : &uap->dmarx.sgbuf_a; + dbuf = dmarx->use_buf_b ? &uap->dmarx.dbuf_b : &uap->dmarx.dbuf_a; rxchan->device->device_tx_status(rxchan, dmarx->cookie, &state); if (likely(state.residue < dmarx->last_residue)) { - dmataken = sgbuf->sg.length - dmarx->last_residue; + dmataken = dbuf->len - dmarx->last_residue; size = dmarx->last_residue - state.residue; - dma_count = tty_insert_flip_string(port, sgbuf->buf + dmataken, + dma_count = tty_insert_flip_string(port, dbuf->buf + dmataken, size); if (dma_count == size) dmarx->last_residue = state.residue; @@@ -1123,7 -1118,7 +1118,7 @@@ static void pl011_dma_startup(struct ua return; } - sg_init_one(&uap->dmatx.sg, uap->dmatx.buf, PL011_DMA_BUFFER_SIZE); + uap->dmatx.len = PL011_DMA_BUFFER_SIZE; /* The DMA buffer is now the FIFO the TTY subsystem can use */ uap->port.fifosize = PL011_DMA_BUFFER_SIZE; @@@ -1133,7 -1128,7 +1128,7 @@@ goto skip_rx; /* Allocate and map DMA RX buffers */ - ret = pl011_sgbuf_init(uap->dmarx.chan, &uap->dmarx.sgbuf_a, + ret = pl011_dmabuf_init(uap->dmarx.chan, &uap->dmarx.dbuf_a, DMA_FROM_DEVICE); if (ret) { dev_err(uap->port.dev, "failed to init DMA %s: %d\n", @@@ -1141,12 -1136,12 +1136,12 @@@ goto skip_rx; } - ret = pl011_sgbuf_init(uap->dmarx.chan, &uap->dmarx.sgbuf_b, + ret = pl011_dmabuf_init(uap->dmarx.chan, &uap->dmarx.dbuf_b, DMA_FROM_DEVICE); if (ret) { dev_err(uap->port.dev, "failed to init DMA %s: %d\n", "RX buffer B", ret); - pl011_sgbuf_free(uap->dmarx.chan, &uap->dmarx.sgbuf_a, + pl011_dmabuf_free(uap->dmarx.chan, &uap->dmarx.dbuf_a, DMA_FROM_DEVICE); goto skip_rx; } @@@ -1200,8 -1195,9 +1195,9 @@@ static void pl011_dma_shutdown(struct u /* In theory, this should already be done by pl011_dma_flush_buffer */ dmaengine_terminate_all(uap->dmatx.chan); if (uap->dmatx.queued) { - dma_unmap_sg(uap->dmatx.chan->device->dev, &uap->dmatx.sg, 1, - DMA_TO_DEVICE); + dma_unmap_single(uap->dmatx.chan->device->dev, + uap->dmatx.dma, uap->dmatx.len, + DMA_TO_DEVICE); uap->dmatx.queued = false; } @@@ -1212,8 -1208,8 +1208,8 @@@ if (uap->using_rx_dma) { dmaengine_terminate_all(uap->dmarx.chan); /* Clean up the RX DMA */ - pl011_sgbuf_free(uap->dmarx.chan, &uap->dmarx.sgbuf_a, DMA_FROM_DEVICE); - pl011_sgbuf_free(uap->dmarx.chan, &uap->dmarx.sgbuf_b, DMA_FROM_DEVICE); + pl011_dmabuf_free(uap->dmarx.chan, &uap->dmarx.dbuf_a, DMA_FROM_DEVICE); + pl011_dmabuf_free(uap->dmarx.chan, &uap->dmarx.dbuf_b, DMA_FROM_DEVICE); if (uap->dmarx.poll_rate) del_timer_sync(&uap->dmarx.timer); uap->using_rx_dma = false; @@@ -2939,12 -2935,13 +2935,12 @@@ static int sbsa_uart_probe(struct platf return pl011_register_port(uap); } -static int sbsa_uart_remove(struct platform_device *pdev) +static void sbsa_uart_remove(struct platform_device *pdev) { struct uart_amba_port *uap = platform_get_drvdata(pdev); uart_remove_one_port(&amba_reg, &uap->port); pl011_unregister_port(uap); - return 0; } static const struct of_device_id sbsa_uart_of_match[] = { @@@ -2962,7 -2959,7 +2958,7 @@@ MODULE_DEVICE_TABLE(acpi, sbsa_uart_acp static struct platform_driver arm_sbsa_uart_platform_driver = { .probe = sbsa_uart_probe, - .remove = sbsa_uart_remove, + .remove_new = sbsa_uart_remove, .driver = { .name = "sbsa-uart", .pm = &pl011_dev_pm_ops, diff --combined drivers/tty/serial/ma35d1_serial.c index f9c6c75d9776,21b574f78b86..b4dcbd0c95bf --- a/drivers/tty/serial/ma35d1_serial.c +++ b/drivers/tty/serial/ma35d1_serial.c @@@ -552,11 -552,19 +552,19 @@@ static void ma35d1serial_console_putcha */ static void ma35d1serial_console_write(struct console *co, const char *s, u32 count) { - struct uart_ma35d1_port *up = &ma35d1serial_ports[co->index]; + struct uart_ma35d1_port *up; unsigned long flags; int locked = 1; u32 ier; + if ((co->index < 0) || (co->index >= MA35_UART_NR)) { + pr_warn("Failed to write on ononsole port %x, out of range\n", + co->index); + return; + } + + up = &ma35d1serial_ports[co->index]; + if (up->port.sysrq) locked = 0; else if (oops_in_progress) @@@ -746,13 -754,14 +754,13 @@@ err_iounmap /* * Remove serial ports registered against a platform device. */ -static int ma35d1serial_remove(struct platform_device *dev) +static void ma35d1serial_remove(struct platform_device *dev) { struct uart_port *port = platform_get_drvdata(dev); struct uart_ma35d1_port *up = to_ma35d1_uart_port(port); uart_remove_one_port(&ma35d1serial_reg, port); clk_disable_unprepare(up->clk); - return 0; } static int ma35d1serial_suspend(struct platform_device *dev, pm_message_t state) @@@ -785,7 -794,7 +793,7 @@@ static int ma35d1serial_resume(struct p static struct platform_driver ma35d1serial_driver = { .probe = ma35d1serial_probe, - .remove = ma35d1serial_remove, + .remove_new = ma35d1serial_remove, .suspend = ma35d1serial_suspend, .resume = ma35d1serial_resume, .driver = { diff --combined drivers/tty/serial/sc16is7xx.c index 10e90a7774f0,cf0c6120d30e..9cb503169a48 --- a/drivers/tty/serial/sc16is7xx.c +++ b/drivers/tty/serial/sc16is7xx.c @@@ -300,8 -300,8 +300,8 @@@ /* Misc definitions */ +#define SC16IS7XX_SPI_READ_BIT BIT(7) #define SC16IS7XX_FIFO_SIZE (64) -#define SC16IS7XX_REG_SHIFT 2 #define SC16IS7XX_GPIOS_PER_BANK 4 struct sc16is7xx_devtype { @@@ -323,7 -323,6 +323,7 @@@ struct sc16is7xx_one_config struct sc16is7xx_one { struct uart_port port; u8 line; + struct regmap *regmap; struct kthread_work tx_work; struct kthread_work reg_work; struct kthread_delayed_work ms_work; @@@ -361,37 -360,48 +361,37 @@@ static void sc16is7xx_stop_tx(struct ua #define to_sc16is7xx_one(p,e) ((container_of((p), struct sc16is7xx_one, e))) -static int sc16is7xx_line(struct uart_port *port) -{ - struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); - - return one->line; -} - static u8 sc16is7xx_port_read(struct uart_port *port, u8 reg) { - struct sc16is7xx_port *s = dev_get_drvdata(port->dev); + struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); unsigned int val = 0; - const u8 line = sc16is7xx_line(port); - regmap_read(s->regmap, (reg << SC16IS7XX_REG_SHIFT) | line, &val); + regmap_read(one->regmap, reg, &val); return val; } static void sc16is7xx_port_write(struct uart_port *port, u8 reg, u8 val) { - struct sc16is7xx_port *s = dev_get_drvdata(port->dev); - const u8 line = sc16is7xx_line(port); + struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); - regmap_write(s->regmap, (reg << SC16IS7XX_REG_SHIFT) | line, val); + regmap_write(one->regmap, reg, val); } static void sc16is7xx_fifo_read(struct uart_port *port, unsigned int rxlen) { struct sc16is7xx_port *s = dev_get_drvdata(port->dev); - const u8 line = sc16is7xx_line(port); - u8 addr = (SC16IS7XX_RHR_REG << SC16IS7XX_REG_SHIFT) | line; + struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); - regcache_cache_bypass(s->regmap, true); - regmap_raw_read(s->regmap, addr, s->buf, rxlen); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(one->regmap, true); + regmap_raw_read(one->regmap, SC16IS7XX_RHR_REG, s->buf, rxlen); + regcache_cache_bypass(one->regmap, false); } static void sc16is7xx_fifo_write(struct uart_port *port, u8 to_send) { struct sc16is7xx_port *s = dev_get_drvdata(port->dev); - const u8 line = sc16is7xx_line(port); - u8 addr = (SC16IS7XX_THR_REG << SC16IS7XX_REG_SHIFT) | line; + struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); /* * Don't send zero-length data, at least on SPI it confuses the chip @@@ -400,17 -410,19 +400,17 @@@ if (unlikely(!to_send)) return; - regcache_cache_bypass(s->regmap, true); - regmap_raw_write(s->regmap, addr, s->buf, to_send); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(one->regmap, true); + regmap_raw_write(one->regmap, SC16IS7XX_THR_REG, s->buf, to_send); + regcache_cache_bypass(one->regmap, false); } static void sc16is7xx_port_update(struct uart_port *port, u8 reg, u8 mask, u8 val) { - struct sc16is7xx_port *s = dev_get_drvdata(port->dev); - const u8 line = sc16is7xx_line(port); + struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); - regmap_update_bits(s->regmap, (reg << SC16IS7XX_REG_SHIFT) | line, - mask, val); + regmap_update_bits(one->regmap, reg, mask, val); } static int sc16is7xx_alloc_line(void) @@@ -465,7 -477,7 +465,7 @@@ static const struct sc16is7xx_devtype s static bool sc16is7xx_regmap_volatile(struct device *dev, unsigned int reg) { - switch (reg >> SC16IS7XX_REG_SHIFT) { + switch (reg) { case SC16IS7XX_RHR_REG: case SC16IS7XX_IIR_REG: case SC16IS7XX_LSR_REG: @@@ -484,7 -496,7 +484,7 @@@ static bool sc16is7xx_regmap_precious(struct device *dev, unsigned int reg) { - switch (reg >> SC16IS7XX_REG_SHIFT) { + switch (reg) { case SC16IS7XX_RHR_REG: return true; default: @@@ -497,7 -509,6 +497,7 @@@ static int sc16is7xx_set_baud(struct uart_port *port, int baud) { struct sc16is7xx_port *s = dev_get_drvdata(port->dev); + struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); u8 lcr; u8 prescaler = 0; unsigned long clk = port->uartclk, div = clk / 16 / baud; @@@ -529,12 -540,12 +529,12 @@@ SC16IS7XX_LCR_CONF_MODE_B); /* Enable enhanced features */ - regcache_cache_bypass(s->regmap, true); + regcache_cache_bypass(one->regmap, true); sc16is7xx_port_update(port, SC16IS7XX_EFR_REG, SC16IS7XX_EFR_ENABLE_BIT, SC16IS7XX_EFR_ENABLE_BIT); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(one->regmap, false); /* Put LCR back to the normal mode */ sc16is7xx_port_write(port, SC16IS7XX_LCR_REG, lcr); @@@ -550,10 -561,10 +550,10 @@@ SC16IS7XX_LCR_CONF_MODE_A); /* Write the new divisor */ - regcache_cache_bypass(s->regmap, true); + regcache_cache_bypass(one->regmap, true); sc16is7xx_port_write(port, SC16IS7XX_DLH_REG, div / 256); sc16is7xx_port_write(port, SC16IS7XX_DLL_REG, div % 256); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(one->regmap, false); /* Put LCR back to the normal mode */ sc16is7xx_port_write(port, SC16IS7XX_LCR_REG, lcr); @@@ -664,7 -675,7 +664,7 @@@ static void sc16is7xx_handle_tx(struct /* Get length of data pending in circular buffer */ to_send = uart_circ_chars_pending(xmit); if (likely(to_send)) { - /* Limit to size of TX FIFO */ + /* Limit to space available in TX FIFO */ txlen = sc16is7xx_port_read(port, SC16IS7XX_TXLVL_REG); if (txlen > SC16IS7XX_FIFO_SIZE) { dev_err_ratelimited(port->dev, @@@ -755,6 -766,18 +755,18 @@@ static bool sc16is7xx_port_irq(struct s case SC16IS7XX_IIR_RTOI_SRC: case SC16IS7XX_IIR_XOFFI_SRC: rxlen = sc16is7xx_port_read(port, SC16IS7XX_RXLVL_REG); + + /* + * There is a silicon bug that makes the chip report a + * time-out interrupt but no data in the FIFO. This is + * described in errata section 18.1.4. + * + * When this happens, read one byte from the FIFO to + * clear the interrupt. + */ + if (iir == SC16IS7XX_IIR_RTOI_SRC && !rxlen) + rxlen = 1; + if (rxlen) sc16is7xx_handle_rx(port, rxlen, iir); break; @@@ -1067,7 -1090,7 +1079,7 @@@ static void sc16is7xx_set_termios(struc SC16IS7XX_LCR_CONF_MODE_B); /* Configure flow control */ - regcache_cache_bypass(s->regmap, true); + regcache_cache_bypass(one->regmap, true); sc16is7xx_port_write(port, SC16IS7XX_XON1_REG, termios->c_cc[VSTART]); sc16is7xx_port_write(port, SC16IS7XX_XOFF1_REG, termios->c_cc[VSTOP]); @@@ -1086,7 -1109,7 +1098,7 @@@ SC16IS7XX_EFR_REG, SC16IS7XX_EFR_FLOWCTRL_BITS, flow); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(one->regmap, false); /* Update LCR register */ sc16is7xx_port_write(port, SC16IS7XX_LCR_REG, lcr); @@@ -1137,6 -1160,7 +1149,6 @@@ static int sc16is7xx_config_rs485(struc static int sc16is7xx_startup(struct uart_port *port) { struct sc16is7xx_one *one = to_sc16is7xx_one(port, port); - struct sc16is7xx_port *s = dev_get_drvdata(port->dev); unsigned int val; unsigned long flags; @@@ -1153,7 -1177,7 +1165,7 @@@ sc16is7xx_port_write(port, SC16IS7XX_LCR_REG, SC16IS7XX_LCR_CONF_MODE_B); - regcache_cache_bypass(s->regmap, true); + regcache_cache_bypass(one->regmap, true); /* Enable write access to enhanced features and internal clock div */ sc16is7xx_port_update(port, SC16IS7XX_EFR_REG, @@@ -1171,7 -1195,7 +1183,7 @@@ SC16IS7XX_TCR_RX_RESUME(24) | SC16IS7XX_TCR_RX_HALT(48)); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(one->regmap, false); /* Now, initialize the UART */ sc16is7xx_port_write(port, SC16IS7XX_LCR_REG, SC16IS7XX_LCR_WORD_LEN_8); @@@ -1452,7 -1476,7 +1464,7 @@@ static int sc16is7xx_setup_mctrl_ports( if (s->mctrl_mask) regmap_update_bits( s->regmap, - SC16IS7XX_IOCONTROL_REG << SC16IS7XX_REG_SHIFT, + SC16IS7XX_IOCONTROL_REG, SC16IS7XX_IOCONTROL_MODEM_A_BIT | SC16IS7XX_IOCONTROL_MODEM_B_BIT, s->mctrl_mask); @@@ -1467,7 -1491,7 +1479,7 @@@ static const struct serial_rs485 sc16is static int sc16is7xx_probe(struct device *dev, const struct sc16is7xx_devtype *devtype, - struct regmap *regmap, int irq) + struct regmap *regmaps[], int irq) { unsigned long freq = 0, *pfreq = dev_get_platdata(dev); unsigned int val; @@@ -1475,16 -1499,16 +1487,16 @@@ int i, ret; struct sc16is7xx_port *s; - if (IS_ERR(regmap)) - return PTR_ERR(regmap); + for (i = 0; i < devtype->nr_uart; i++) + if (IS_ERR(regmaps[i])) + return PTR_ERR(regmaps[i]); /* * This device does not have an identification register that would * tell us if we are really connected to the correct device. * The best we can do is to check if communication is at all possible. */ - ret = regmap_read(regmap, - SC16IS7XX_LSR_REG << SC16IS7XX_REG_SHIFT, &val); + ret = regmap_read(regmaps[0], SC16IS7XX_LSR_REG, &val); if (ret < 0) return -EPROBE_DEFER; @@@ -1518,7 -1542,7 +1530,7 @@@ return -EINVAL; } - s->regmap = regmap; + s->regmap = regmaps[0]; s->devtype = devtype; dev_set_drvdata(dev, s); mutex_init(&s->efr_lock); @@@ -1533,8 -1557,8 +1545,8 @@@ sched_set_fifo(s->kworker_task); /* reset device, purging any pending irq / data */ - regmap_write(s->regmap, SC16IS7XX_IOCONTROL_REG << SC16IS7XX_REG_SHIFT, - SC16IS7XX_IOCONTROL_SRESET_BIT); + regmap_write(s->regmap, SC16IS7XX_IOCONTROL_REG, + SC16IS7XX_IOCONTROL_SRESET_BIT); for (i = 0; i < devtype->nr_uart; ++i) { s->p[i].line = i; @@@ -1558,7 -1582,6 +1570,7 @@@ s->p[i].port.ops = &sc16is7xx_ops; s->p[i].old_mctrl = 0; s->p[i].port.line = sc16is7xx_alloc_line(); + s->p[i].regmap = regmaps[i]; if (s->p[i].port.line >= SC16IS7XX_MAX_DEVS) { ret = -ENOMEM; @@@ -1587,13 -1610,13 +1599,13 @@@ sc16is7xx_port_write(&s->p[i].port, SC16IS7XX_LCR_REG, SC16IS7XX_LCR_CONF_MODE_B); - regcache_cache_bypass(s->regmap, true); + regcache_cache_bypass(regmaps[i], true); /* Enable write access to enhanced features */ sc16is7xx_port_write(&s->p[i].port, SC16IS7XX_EFR_REG, SC16IS7XX_EFR_ENABLE_BIT); - regcache_cache_bypass(s->regmap, false); + regcache_cache_bypass(regmaps[i], false); /* Restore access to general registers */ sc16is7xx_port_write(&s->p[i].port, SC16IS7XX_LCR_REG, 0x00); @@@ -1687,36 -1710,19 +1699,36 @@@ static const struct of_device_id __mayb MODULE_DEVICE_TABLE(of, sc16is7xx_dt_ids); static struct regmap_config regcfg = { - .reg_bits = 7, - .pad_bits = 1, + .reg_bits = 5, + .pad_bits = 3, .val_bits = 8, .cache_type = REGCACHE_RBTREE, .volatile_reg = sc16is7xx_regmap_volatile, .precious_reg = sc16is7xx_regmap_precious, + .max_register = SC16IS7XX_EFCR_REG, }; +static const char *sc16is7xx_regmap_name(unsigned int port_id) +{ + static char buf[6]; + + snprintf(buf, sizeof(buf), "port%d", port_id); + + return buf; +} + +static unsigned int sc16is7xx_regmap_port_mask(unsigned int port_id) +{ + /* CH1,CH0 are at bits 2:1. */ + return port_id << 1; +} + #ifdef CONFIG_SERIAL_SC16IS7XX_SPI static int sc16is7xx_spi_probe(struct spi_device *spi) { const struct sc16is7xx_devtype *devtype; - struct regmap *regmap; + struct regmap *regmaps[2]; + unsigned int i; int ret; /* Setup SPI bus */ @@@ -1738,20 -1744,11 +1750,20 @@@ devtype = (struct sc16is7xx_devtype *)id_entry->driver_data; } - regcfg.max_register = (0xf << SC16IS7XX_REG_SHIFT) | - (devtype->nr_uart - 1); - regmap = devm_regmap_init_spi(spi, ®cfg); + for (i = 0; i < devtype->nr_uart; i++) { + regcfg.name = sc16is7xx_regmap_name(i); + /* + * If read_flag_mask is 0, the regmap code sets it to a default + * of 0x80. Since we specify our own mask, we must add the READ + * bit ourselves: + */ + regcfg.read_flag_mask = sc16is7xx_regmap_port_mask(i) | + SC16IS7XX_SPI_READ_BIT; + regcfg.write_flag_mask = sc16is7xx_regmap_port_mask(i); + regmaps[i] = devm_regmap_init_spi(spi, ®cfg); + } - return sc16is7xx_probe(&spi->dev, devtype, regmap, spi->irq); + return sc16is7xx_probe(&spi->dev, devtype, regmaps, spi->irq); } static void sc16is7xx_spi_remove(struct spi_device *spi) @@@ -1790,8 -1787,7 +1802,8 @@@ static int sc16is7xx_i2c_probe(struct i { const struct i2c_device_id *id = i2c_client_get_device_id(i2c); const struct sc16is7xx_devtype *devtype; - struct regmap *regmap; + struct regmap *regmaps[2]; + unsigned int i; if (i2c->dev.of_node) { devtype = device_get_match_data(&i2c->dev); @@@ -1801,14 -1797,11 +1813,14 @@@ devtype = (struct sc16is7xx_devtype *)id->driver_data; } - regcfg.max_register = (0xf << SC16IS7XX_REG_SHIFT) | - (devtype->nr_uart - 1); - regmap = devm_regmap_init_i2c(i2c, ®cfg); + for (i = 0; i < devtype->nr_uart; i++) { + regcfg.name = sc16is7xx_regmap_name(i); + regcfg.read_flag_mask = sc16is7xx_regmap_port_mask(i); + regcfg.write_flag_mask = sc16is7xx_regmap_port_mask(i); + regmaps[i] = devm_regmap_init_i2c(i2c, ®cfg); + } - return sc16is7xx_probe(&i2c->dev, devtype, regmap, i2c->irq); + return sc16is7xx_probe(&i2c->dev, devtype, regmaps, i2c->irq); } static void sc16is7xx_i2c_remove(struct i2c_client *client)