1. 18 Oct, 2021 6 commits
    • Linus Torvalds's avatar
      Merge tag 'driver-core-5.15-rc6' of... · cf52ad5f
      Linus Torvalds authored
      Merge tag 'driver-core-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
      
      Pull driver core fixes from Greg KH:
       "Here are some small driver core fixes for 5.15-rc6, all of which have
        been in linux-next for a while with no reported issues.
      
        They include:
      
         - kernfs negative dentry bugfix
      
         - simple pm bus fixes to resolve reported issues"
      
      * tag 'driver-core-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
        drivers: bus: Delete CONFIG_SIMPLE_PM_BUS
        drivers: bus: simple-pm-bus: Add support for probing simple bus only devices
        driver core: Reject pointless SYNC_STATE_ONLY device links
        kernfs: don't create a negative dentry if inactive node exists
      cf52ad5f
    • Linus Torvalds's avatar
      Merge tag 'char-misc-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc · e3572dff
      Linus Torvalds authored
      Pull char/misc driver fixes from Greg KH:
       "Here are some small char/misc driver fixes for 5.15-rc6 for reported
        issues that include:
      
         - habanalabs driver fixes
      
         - mei driver fixes and new ids
      
         - fpga new device ids
      
         - MAINTAINER file updates for fpga subsystem
      
         - spi module id table additions and fixes
      
         - fastrpc locking fixes
      
         - nvmem driver fix
      
        All of these have been in linux-next for a while with no reported
        issues"
      
      * tag 'char-misc-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
        eeprom: 93xx46: fix MODULE_DEVICE_TABLE
        nvmem: Fix shift-out-of-bound (UBSAN) with byte size cells
        mei: hbm: drop hbm responses on early shutdown
        mei: me: add Ice Lake-N device id.
        eeprom: 93xx46: Add SPI device ID table
        eeprom: at25: Add SPI ID table
        misc: HI6421V600_IRQ should depend on HAS_IOMEM
        misc: fastrpc: Add missing lock before accessing find_vma()
        cb710: avoid NULL pointer subtraction
        misc: gehc: Add SPI ID table
        MAINTAINERS: Drop outdated FPGA Manager website
        MAINTAINERS: Add Hao and Yilun as maintainers
        habanalabs: fix resetting args in wait for CS IOCTL
        fpga: ice40-spi: Add SPI device ID table
      e3572dff
    • Linus Torvalds's avatar
      Merge tag 'staging-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging · a563ae0f
      Linus Torvalds authored
      Pull staging and IIO driver fixes from Greg KH:
       "Here are a number of small IIO and staging driver fixes for 5.15-rc6.
      
        They include:
      
         - vc04_services bugfix for reported problem
      
         - r8188eu array underflow fix
      
         - iio driver fixes for a lot of tiny reported issues.
      
        All of these have been in linux-next for a while with no reported
        issues"
      
      * tag 'staging-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
        staging: r8188eu: prevent array underflow in rtw_hal_update_ra_mask()
        staging: vc04_services: shut up out-of-range warning
        iio: light: opt3001: Fixed timeout error when 0 lux
        iio: adis16480: fix devices that do not support sleep mode
        iio: mtk-auxadc: fix case IIO_CHAN_INFO_PROCESSED
        iio: adis16475: fix deadlock on frequency set
        iio: ssp_sensors: add more range checking in ssp_parse_dataframe()
        iio: ssp_sensors: fix error code in ssp_print_mcu_debug()
        iio: adc: ad7793: Fix IRQ flag
        iio: adc: ad7780: Fix IRQ flag
        iio: adc: ad7192: Add IRQ flag
        iio: adc: aspeed: set driver data when adc probe.
        iio: adc: rzg2l_adc: add missing clk_disable_unprepare() in rzg2l_adc_pm_runtime_resume()
        iio: adc: max1027: Fix the number of max1X31 channels
        iio: adc: max1027: Fix wrong shift with 12-bit devices
        iio: adc128s052: Fix the error handling path of 'adc128_probe()'
        iio: adc: rzg2l_adc: Fix -EBUSY timeout error return
        iio: accel: fxls8962af: return IRQ_HANDLED when fifo is flushed
        iio: dac: ti-dac5571: fix an error code in probe()
      a563ae0f
    • Linus Torvalds's avatar
      Merge tag 'tty-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty · b9e42b3c
      Linus Torvalds authored
      Pull serial driver fix from Greg KH:
       "Here is a single 8250 Kconfig fix for 5.15-rc6 that resolves a
        regression that showed up in 5.15-rc1. It has been in linux-next for a
        while with no reported issues"
      
      * tag 'tty-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
        serial: 8250: allow disabling of Freescale 16550 compile test
      b9e42b3c
    • Linus Torvalds's avatar
      Merge tag 'usb-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · ebf613ae
      Linus Torvalds authored
      Pull USB fixes from Greg KH:
       "Here are some small USB fixes that resolve a number of tiny issues.
        They include:
      
         - new USB serial driver ids
      
         - xhci driver fixes for a bunch of issues
      
         - musb error path fixes.
      
        All of these have been in linux-next for a while with no reported
        issues"
      
      * tag 'usb-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
        usb: musb: dsps: Fix the probe error path
        xhci: Enable trust tx length quirk for Fresco FL11 USB controller
        xhci: Fix command ring pointer corruption while aborting a command
        USB: xhci: dbc: fix tty registration race
        xhci: add quirk for host controllers that don't update endpoint DCS
        xhci: guard accesses to ep_state in xhci_endpoint_reset()
        USB: serial: qcserial: add EM9191 QDL support
        USB: serial: option: add Quectel EC200S-CN module support
        USB: serial: option: add prod. id for Quectel EG91
        USB: serial: option: add Telit LE910Cx composition 0x1204
      ebf613ae
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input · 12dbbfad
      Linus Torvalds authored
      Pull input fixes from Dmitry Torokhov:
      
       - a new product ID for the xpad joystick driver
      
       - fixes to resistive-adc-touch and snvs_pwrkey drivers
      
       - a change to touchscreen helpers to make clang happier
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
        Input: touchscreen - avoid bitwise vs logical OR warning
        Input: xpad - add support for another USB ID of Nacon GC-100
        Input: resistive-adc-touch - fix division by zero error on z1 == 0
        Input: snvs_pwrkey - add clk handling
      12dbbfad
  2. 16 Oct, 2021 17 commits
  3. 15 Oct, 2021 17 commits
    • Guenter Roeck's avatar
      csky: Make HAVE_TCM depend on !COMPILE_TEST · e21e52ad
      Guenter Roeck authored
      Building csky:allmodconfig results in the following build errors.
      
      arch/csky/mm/tcm.c:9:2: error:
      		#error "You should define ITCM_RAM_BASE"
          9 | #error "You should define ITCM_RAM_BASE"
            |  ^~~~~
      arch/csky/mm/tcm.c:14:2: error:
      		#error "You should define DTCM_RAM_BASE"
         14 | #error "You should define DTCM_RAM_BASE"
            |  ^~~~~
      arch/csky/mm/tcm.c:18:2: error:
      		#error "You should define correct DTCM_RAM_BASE"
         18 | #error "You should define correct DTCM_RAM_BASE"
      
      This is seen with compile tests since those enable HAVE_TCM,
      but do not provide useful default values for ITCM_RAM_BASE or
      DTCM_RAM_BASE. Disable HAVE_TCM for commpile tests to avoid
      the error.
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: default avatarGuo Ren <guoren@kernel.org>
      e21e52ad
    • Guenter Roeck's avatar
      csky: bitops: Remove duplicate __clear_bit define · fb5d69a5
      Guenter Roeck authored
      Building csky:allmodconfig results in the following build error.
      
      In file included from ./include/linux/bitops.h:33,
                       from ./include/linux/log2.h:12,
                       from kernel/bounds.c:13:
      ./arch/csky/include/asm/bitops.h:77: error: "__clear_bit" redefined
      
      Since commit 9248e52f ("locking/atomic: simplify non-atomic wrappers"),
      __clear_bit is defined in include/asm-generic/bitops/non-atomic.h,
      and the define in the csky include file is no longer necessary or useful.
      Remove it.
      
      Fixes: 9248e52f ("locking/atomic: simplify non-atomic wrappers")
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: default avatarGuo Ren <guoren@kernel.org>
      fb5d69a5
    • Guenter Roeck's avatar
      csky: Select ARCH_WANT_FRAME_POINTERS only if compiler supports it · aeba0b84
      Guenter Roeck authored
      Compiling csky:allmodconfig with an upstream C compiler results
      in the following error.
      
      csky-linux-gcc: error:
      	unrecognized command-line option '-mbacktrace';
      	did you mean '-fbacktrace'?
      
      Select ARCH_WANT_FRAME_POINTERS only if gcc supports it to
      avoid the error.
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: default avatarGuo Ren <guoren@kernel.org>
      aeba0b84
    • Guo Ren's avatar
      csky: Fixup regs.sr broken in ptrace · af89ebaa
      Guo Ren authored
      gpr_get() return the entire pt_regs (include sr) to userspace, if we
      don't restore the C bit in gpr_set, it may break the ALU result in
      that context. So the C flag bit is part of gpr context, that's why
      riscv totally remove the C bit in the ISA. That makes sr reg clear
      from userspace to supervisor privilege.
      Signed-off-by: default avatarGuo Ren <guoren@linux.alibaba.com>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Cc: stable@vger.kernel.org
      af89ebaa
    • Al Viro's avatar
      csky: don't let sigreturn play with priveleged bits of status register · fbd63c08
      Al Viro authored
      csky restore_sigcontext() blindly overwrites regs->sr with the value
      it finds in sigcontext.  Attacker can store whatever they want in there,
      which includes things like S-bit.  Userland shouldn't be able to set
      that, or anything other than C flag (bit 0).
      
      Do the same thing other architectures with protected bits in flags
      register do - preserve everything that shouldn't be settable in
      user mode, picking the rest from the value saved is sigcontext.
      Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: default avatarGuo Ren <guoren@kernel.org>
      Cc: stable@vger.kernel.org
      fbd63c08
    • Arnd Bergmann's avatar
      Merge tag 'imx-fixes-5.15-3' of... · 011ace4a
      Arnd Bergmann authored
      Merge tag 'imx-fixes-5.15-3' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into arm/fixes
      
      i.MX fixes for 5.15, round 3:
      
      - Add platform device for i.MX System Reset Controller (SRC) to fix
        a regression caused by fw_devlink change.
      
      * tag 'imx-fixes-5.15-3' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux:
        ARM: imx: register reset controller from a platform driver
      
      Link: https://lore.kernel.org/r/20211015070017.GI22881@dragonSigned-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      011ace4a
    • Linus Torvalds's avatar
      Merge tag 'gpio-fixes-for-v5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux · 8fe31e09
      Linus Torvalds authored
      Pull gpio fixes from Bartosz Golaszewski:
      
       - fix module autoloading on gpio-74x164 after a revert of OF modaliases
      
       - fix problems with the bias setting in gpio-pca953x
      
       - fix a use-after-free bug in gpio-mockup by using software nodes
      
      * tag 'gpio-fixes-for-v5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
        gpio: mockup: Convert to use software nodes
        gpio: pca953x: Improve bias setting
        gpio: 74x164: Add SPI device ID table
      8fe31e09
    • Linus Torvalds's avatar
      Merge tag 'spi-fix-v5.15-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi · 985f6ab9
      Linus Torvalds authored
      Pull spi fixes from Mark Brown:
       "A few small fixes.
      
        Mostly driver specific but there's one in the core which fixes a
        deadlock when adding devices on spi-mux that's triggered because
        spi-mux is a SPI device which is itself a SPI controller and so can
        instantiate devices when registered.
      
        We were using a global lock to protect against reusing chip selects
        but they're a per controller thing so moving the lock per controller
        resolves that"
      
      * tag 'spi-fix-v5.15-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi:
        spi-mux: Fix false-positive lockdep splats
        spi: Fix deadlock when adding SPI controllers on SPI buses
        spi: bcm-qspi: clear MSPI spifie interrupt during probe
        spi: spi-nxp-fspi: don't depend on a specific node name erratum workaround
        spi: mediatek: skip delays if they are 0
        spi: atmel: Fix PDC transfer setup bug
        spi: spidev: Add SPI ID table
        spi: Use 'flash' node name instead of 'spi-flash' in example
      985f6ab9
    • Linus Torvalds's avatar
      Merge tag 'regulator-fix-v5.15-rc5' of... · ccb6a666
      Linus Torvalds authored
      Merge tag 'regulator-fix-v5.15-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
      
      Pull regulator fix from Mark Brown:
       "Just a trivial fix to the MAINTAINERS file for an update missed during
        conversion of the DT bindings to YAML format"
      
      * tag 'regulator-fix-v5.15-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
        MAINTAINERS: rectify entry for SY8106A REGULATOR DRIVER
      ccb6a666
    • Linus Torvalds's avatar
      Merge tag 'mtd/fixes-for-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux · 9e795d94
      Linus Torvalds authored
      Pull mtd fix from Miquel Raynal:
       "Raw NAND controller driver fix:
      
         - Qcom: Update code word value for raw reads (QPIC v2+)"
      
      * tag 'mtd/fixes-for-5.15-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux:
        mtd: rawnand: qcom: Update code word value for raw read
      9e795d94
    • Linus Torvalds's avatar
      Merge tag 'drm-fixes-2021-10-15-1' of git://anongit.freedesktop.org/drm/drm · 591a495d
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "It has a few scattered msm and i915 fixes, a few core fixes and a
        mediatek feature revert.
      
        I've had to pick a bunch of patches into this, as the drm-misc-fixes
        tree had a bunch of vc4 patches I wasn't comfortable with sending to
        you at least as part of this, they were delayed due to your reverts.
        If it's really useful as fixes I'll do a separate pull.
      
        Summary:
      
        Core:
         - clamp fbdev size
         - edid cap blocks read to avoid out of bounds
      
        panel:
         - fix missing crc32 dependency
      
        msm:
         - Fix a new crash on dev file close if the dev file was opened when
           GPU is not loaded (such as missing fw in initrd)
         - Switch to single drm_sched_entity per priority level per drm_file
           to unbreak multi-context userspace
         - Serialize GMU access to fix GMU OOB errors
         - Various error path fixes
         - A couple integer overflow fixes
         - Fix mdp5 cursor plane WARNs
      
        i915:
         - Fix ACPI object leak
         - Fix context leak in user proto-context creation
         - Fix missing i915_sw_fence_fini call
      
        hyperv:
         - hide hw pointer
      
        nouveau:
         - fix engine selection bit
      
        r128:
         - fix UML build
      
        rcar-du:
         - unconncted LVDS regression fix
      
        mediatek:
         - revert CMDQ refinement patches"
      
      * tag 'drm-fixes-2021-10-15-1' of git://anongit.freedesktop.org/drm/drm: (34 commits)
        drm/panel: olimex-lcd-olinuxino: select CRC32
        drm/r128: fix build for UML
        drm/nouveau/fifo: Reinstate the correct engine bit programming
        drm/hyperv: Fix double mouse pointers
        drm/fbdev: Clamp fbdev surface size if too large
        drm/edid: In connector_bad_edid() cap num_of_ext by num_blocks read
        drm/i915: Free the returned object of acpi_evaluate_dsm()
        drm/i915: Fix bug in user proto-context creation that leaked contexts
        drm: rcar-du: Don't create encoder for unconnected LVDS outputs
        drm/msm/dsi: fix off by one in dsi_bus_clk_enable error handling
        drm/msm/dsi: Fix an error code in msm_dsi_modeset_init()
        drm/msm/dsi: dsi_phy_14nm: Take ready-bit into account in poll_for_ready
        drm/msm/dsi/phy: fix clock names in 28nm_8960 phy
        drm/msm/dpu: Fix address of SM8150 PINGPONG5 IRQ register
        drm/msm: Do not run snapshot on non-DPU devices
        drm/msm/a3xx: fix error handling in a3xx_gpu_init()
        drm/msm/a4xx: fix error handling in a4xx_gpu_init()
        drm/msm: Fix null pointer dereference on pointer edp
        drm/msm/mdp5: fix cursor-related warnings
        drm/msm: Avoid potential overflow in timeout_to_jiffies()
        ...
      591a495d
    • Linus Torvalds's avatar
      Merge tag 'ntfs3_for_5.15' of git://github.com/Paragon-Software-Group/linux-ntfs3 · 86a44e90
      Linus Torvalds authored
      Pull ntfs3 fixes from Konstantin Komarov:
       "Use the new api for mounting as requested by Christoph.
      
        Also fixed:
      
         - some memory leaks and panic
      
         - xfstests (tested on x86_64) generic/016 generic/021 generic/022
           generic/041 generic/274 generic/423
      
         - some typos, wrong returned error codes, dead code, etc"
      
      * tag 'ntfs3_for_5.15' of git://github.com/Paragon-Software-Group/linux-ntfs3: (70 commits)
        fs/ntfs3: Check for NULL pointers in ni_try_remove_attr_list
        fs/ntfs3: Refactor ntfs_read_mft
        fs/ntfs3: Refactor ni_parse_reparse
        fs/ntfs3: Refactor ntfs_create_inode
        fs/ntfs3: Refactor ntfs_readlink_hlp
        fs/ntfs3: Rework ntfs_utf16_to_nls
        fs/ntfs3: Fix memory leak if fill_super failed
        fs/ntfs3: Keep prealloc for all types of files
        fs/ntfs3: Remove unnecessary functions
        fs/ntfs3: Forbid FALLOC_FL_PUNCH_HOLE for normal files
        fs/ntfs3: Refactoring of ntfs_set_ea
        fs/ntfs3: Remove locked argument in ntfs_set_ea
        fs/ntfs3: Use available posix_acl_release instead of ntfs_posix_acl_release
        fs/ntfs3: Check for NULL if ATTR_EA_INFO is incorrect
        fs/ntfs3: Refactoring of ntfs_init_from_boot
        fs/ntfs3: Reject mount if boot's cluster size < media sector size
        fs/ntfs3: Refactoring lock in ntfs_init_acl
        fs/ntfs3: Change posix_acl_equiv_mode to posix_acl_update_mode
        fs/ntfs3: Pass flags to ntfs_set_ea in ntfs_set_acl_ex
        fs/ntfs3: Refactor ntfs_get_acl_ex for better readability
        ...
      86a44e90
    • Greg Kroah-Hartman's avatar
      Merge tag 'usb-serial-5.15-rc6' of... · cd932c2a
      Greg Kroah-Hartman authored
      Merge tag 'usb-serial-5.15-rc6' of https://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-serial into usb-linus
      
      Johan writes:
      
      USB-serial fixes for 5.15-rc6
      
      Here are some new modem device ids.
      
      All have been in linux-next with no reported issues.
      
      * tag 'usb-serial-5.15-rc6' of https://git.kernel.org/pub/scm/linux/kernel/git/johan/usb-serial:
        USB: serial: qcserial: add EM9191 QDL support
        USB: serial: option: add Quectel EC200S-CN module support
        USB: serial: option: add prod. id for Quectel EG91
        USB: serial: option: add Telit LE910Cx composition 0x1204
      cd932c2a
    • Arnd Bergmann's avatar
      eeprom: 93xx46: fix MODULE_DEVICE_TABLE · f4275272
      Arnd Bergmann authored
      The newly added SPI device ID table does not work because the
      entry is incorrectly copied from the OF device table.
      
      During build testing, this shows as a compile failure when building
      it as a loadable module:
      
      drivers/misc/eeprom/eeprom_93xx46.c:424:1: error: redefinition of '__mod_of__eeprom_93xx46_of_table_device_table'
      MODULE_DEVICE_TABLE(of, eeprom_93xx46_of_table);
      
      Change the entry to refer to the correct symbol.
      
      Fixes: 137879f7 ("eeprom: 93xx46: Add SPI device ID table")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Link: https://lore.kernel.org/r/20211014153730.3821376-1-arnd@kernel.orgSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f4275272
    • Vegard Nossum's avatar
      drm/panel: olimex-lcd-olinuxino: select CRC32 · a14bc107
      Vegard Nossum authored
      Fix the following build/link error by adding a dependency on the CRC32
      routines:
      
        ld: drivers/gpu/drm/panel/panel-olimex-lcd-olinuxino.o: in function `lcd_olinuxino_probe':
        panel-olimex-lcd-olinuxino.c:(.text+0x303): undefined reference to `crc32_le'
      
      Fixes: 17fd7a9d ("drm/panel: Add support for Olimex LCD-OLinuXino panel")
      Cc: Arnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarVegard Nossum <vegard.nossum@oracle.com>
      Signed-off-by: default avatarSam Ravnborg <sam@ravnborg.org>
      Link: https://patchwork.freedesktop.org/patch/msgid/20211012115242.10325-1-vegard.nossum@oracle.comSigned-off-by: default avatarDave Airlie <airlied@redhat.com>
      a14bc107
    • Randy Dunlap's avatar
      drm/r128: fix build for UML · 1a361b41
      Randy Dunlap authored
      Fix a build error on CONFIG_UML, which does not support (provide)
      wbinvd(). UML can use the generic mb() instead.
      
      ../drivers/gpu/drm/r128/ati_pcigart.c: In function ‘drm_ati_pcigart_init’:
      ../drivers/gpu/drm/r128/ati_pcigart.c:218:2: error: implicit declaration of function ‘wbinvd’ [-Werror=implicit-function-declaration]
        wbinvd();
        ^~~~~~
      
      Fixes: 68f5d3f3 ("um: add PCI over virtio emulation driver")
      Signed-off-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Cc: David Airlie <airlied@linux.ie>
      Cc: Daniel Vetter <daniel@ffwll.ch>
      Cc: dri-devel@lists.freedesktop.org
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Richard Weinberger <richard@nod.at>
      Cc: Anton Ivanov <anton.ivanov@cambridgegreys.com>
      Cc: linux-um@lists.infradead.org
      Cc: Sam Ravnborg <sam@ravnborg.org>
      Signed-off-by: default avatarSam Ravnborg <sam@ravnborg.org>
      Link: https://patchwork.freedesktop.org/patch/msgid/20211011080006.31081-1-rdunlap@infradead.orgSigned-off-by: default avatarDave Airlie <airlied@redhat.com>
      1a361b41
    • Marek Vasut's avatar
      drm/nouveau/fifo: Reinstate the correct engine bit programming · d1d94b01
      Marek Vasut authored
      Commit 64f7c698 ("drm/nouveau/fifo: add engine_id hook") replaced
      fifo/chang84.c g84_fifo_chan_engine() call with an indirect call of
      fifo/g84.c g84_fifo_engine_id(). The G84_FIFO_ENGN_* values returned
      from the later g84_fifo_engine_id() are incremented by 1 compared to
      the previous g84_fifo_chan_engine() return values.
      
      This is fine either way for most of the code, except this one line
      where an engine bit programmed into the hardware is derived from the
      return value. Decrement the return value accordingly, otherwise the
      wrong engine bit is programmed into the hardware and that leads to
      the following failure:
      nouveau 0000:01:00.0: gr: 00000030 [ILLEGAL_MTHD ILLEGAL_CLASS] ch 1 [003fbce000 DRM] subc 3 class 0000 mthd 085c data 00000420
      
      On the following hardware:
      lspci -s 01:00.0
      01:00.0 VGA compatible controller: NVIDIA Corporation GT216GLM [Quadro FX 880M] (rev a2)
      lspci -ns 01:00.0
      01:00.0 0300: 10de:0a3c (rev a2)
      
      Fixes: 64f7c698 ("drm/nouveau/fifo: add engine_id hook")
      Signed-off-by: default avatarMarek Vasut <marex@denx.de>
      Cc: <stable@vger.kernel.org> # 5.12+
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Cc: Karol Herbst <kherbst@redhat.com>
      Cc: Lyude Paul <lyude@redhat.com>
      Reviewed-by: default avatarKarol Herbst <kherbst@redhat.com>
      Reviewed-by: default avatarBen Skeggs <bskeggs@redhat.com>
      Signed-off-by: default avatarKarol Herbst <kherbst@redhat.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20211007214117.231472-1-marex@denx.deSigned-off-by: default avatarDave Airlie <airlied@redhat.com>
      d1d94b01