1. 29 Sep, 2021 2 commits
  2. 28 Sep, 2021 12 commits
  3. 27 Sep, 2021 1 commit
    • William Cohen's avatar
      perf annotate: Add riscv64 support · 0ba37e05
      William Cohen authored
      This patch adds basic arch initialization and instruction associate
      support for the riscv64 CPU architecture.
      
      Example output:
      
        $ perf annotate --stdio2
        Samples: 122K of event 'task-clock:u', 4000 Hz, Event count (approx.): 30637250000, [percent: local period]
        strcmp() /usr/lib64/libc-2.32.so
        Percent
      
      	      Disassembly of section .text:
      
      	      0000000000069a30 <strcmp>:
      	      __GI_strcmp():
      	      const unsigned char *s2 = (const unsigned char *) p2;
      	      unsigned char c1, c2;
      
      	      do
      	      {
      	      c1 = (unsigned char) *s1++;
         37.30        lbu  a5,0(a0)
      	      c2 = (unsigned char) *s2++;
          1.23        addi a1,a1,1
      	      c1 = (unsigned char) *s1++;
         18.68        addi a0,a0,1
      	      c2 = (unsigned char) *s2++;
          1.37        lbu  a4,-1(a1)
      	      if (c1 == '\0')
         18.71      ↓ beqz a5,18
      	       return c1 - c2;
      	       }
      Signed-off-by: default avatarWilliam Cohen <wcohen@redhat.com>
      Cc: Albert Ou <aou@eecs.berkeley.edu>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Palmer Dabbelt <palmer@dabbelt.com>
      Cc: Paul Walmsley <paul.walmsley@sifive.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: linux-riscv@lists.infradead.org
      Link: http://lore.kernel.org/lkml/20210927005115.610264-1-wcohen@redhat.comSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      0ba37e05
  4. 24 Sep, 2021 1 commit
    • Jin Yao's avatar
      perf list: Display pmu prefix for partially supported hybrid cache events · 6c93f39f
      Jin Yao authored
      Part of hardware cache events are only available on one CPU PMU.
      For example, 'L1-dcache-load-misses' is only available on cpu_core.
      perf list should clearly report this info.
      
      root@otcpl-adl-s-2:~# ./perf list
      
      Before:
        L1-dcache-load-misses                              [Hardware cache event]
        L1-dcache-loads                                    [Hardware cache event]
        L1-dcache-stores                                   [Hardware cache event]
        L1-icache-load-misses                              [Hardware cache event]
        L1-icache-loads                                    [Hardware cache event]
        LLC-load-misses                                    [Hardware cache event]
        LLC-loads                                          [Hardware cache event]
        LLC-store-misses                                   [Hardware cache event]
        LLC-stores                                         [Hardware cache event]
        branch-load-misses                                 [Hardware cache event]
        branch-loads                                       [Hardware cache event]
        dTLB-load-misses                                   [Hardware cache event]
        dTLB-loads                                         [Hardware cache event]
        dTLB-store-misses                                  [Hardware cache event]
        dTLB-stores                                        [Hardware cache event]
        iTLB-load-misses                                   [Hardware cache event]
        node-load-misses                                   [Hardware cache event]
        node-loads                                         [Hardware cache event]
        node-store-misses                                  [Hardware cache event]
        node-stores                                        [Hardware cache event]
      
      After:
        L1-dcache-loads                                    [Hardware cache event]
        L1-dcache-stores                                   [Hardware cache event]
        L1-icache-load-misses                              [Hardware cache event]
        LLC-load-misses                                    [Hardware cache event]
        LLC-loads                                          [Hardware cache event]
        LLC-store-misses                                   [Hardware cache event]
        LLC-stores                                         [Hardware cache event]
        branch-load-misses                                 [Hardware cache event]
        branch-loads                                       [Hardware cache event]
        cpu_atom/L1-icache-loads/                          [Hardware cache event]
        cpu_core/L1-dcache-load-misses/                    [Hardware cache event]
        cpu_core/node-load-misses/                         [Hardware cache event]
        cpu_core/node-loads/                               [Hardware cache event]
        dTLB-load-misses                                   [Hardware cache event]
        dTLB-loads                                         [Hardware cache event]
        dTLB-store-misses                                  [Hardware cache event]
        dTLB-stores                                        [Hardware cache event]
        iTLB-load-misses                                   [Hardware cache event]
      
      Now we can clearly see 'L1-dcache-load-misses' is only available
      on cpu_core.
      
      If without pmu prefix, it indicates the event is available on both
      cpu_core and cpu_atom.
      Signed-off-by: default avatarJin Yao <yao.jin@linux.intel.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Andi Kleen <ak@linux.intel.com>
      Cc: Jin Yao <yao.jin@intel.com>
      Cc: Jiri Olsa <jolsa@kernel.org>
      Cc: Kan Liang <kan.liang@linux.intel.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: http://lore.kernel.org/lkml/20210909061844.10221-1-yao.jin@linux.intel.comSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      6c93f39f
  5. 21 Sep, 2021 5 commits
  6. 20 Sep, 2021 9 commits
    • Linus Torvalds's avatar
      Merge tag 'afs-fixes-20210913' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs · d9fb6784
      Linus Torvalds authored
      Pull AFS fixes from David Howells:
       "Fixes for AFS problems that can cause data corruption due to
        interaction with another client modifying data cached locally:
      
         - When d_revalidating a dentry, don't look at the inode to which it
           points. Only check the directory to which the dentry belongs. This
           was confusing things and causing the silly-rename cleanup code to
           remove the file now at the dentry of a file that got deleted.
      
         - Fix mmap data coherency. When a callback break is received that
           relates to a file that we have cached, the data content may have
           been changed (there are other reasons, such as the user's rights
           having been changed). However, we're checking it lazily, only on
           entry to the kernel, which doesn't happen if we have a writeable
           shared mapped page on that file.
      
           We make the kernel keep track of mmapped files and clear all PTEs
           mapping to that file as soon as the callback comes in by calling
           unmap_mapping_pages() (we don't necessarily want to zap the
           pagecache). This causes the kernel to be reentered when userspace
           tries to access the mmapped address range again - and at that point
           we can query the server and, if we need to, zap the page cache.
      
           Ideally, I would check each file at the point of notification, but
           that involves poking the server[*] - which is holding an exclusive
           lock on the vnode it is changing, waiting for all the clients it
           notified to reply. This could then deadlock against the server.
           Further, invalidating the pagecache might call ->launder_page(),
           which would try to write to the file, which would definitely
           deadlock. (AFS doesn't lease file access).
      
           [*] Checking to see if the file content has changed is a matter of
               comparing the current data version number, but we have to ask
               the server for that. We also need to get a new callback promise
               and we need to poke the server for that too.
      
         - Add some more points at which the inode is validated, since we're
           doing it lazily, notably in ->read_iter() and ->page_mkwrite(), but
           also when performing some directory operations.
      
           Ideally, checking in ->read_iter() would be done in some derivation
           of filemap_read(). If we're going to call the server to read the
           file, then we get the file status fetch as part of that.
      
         - The above is now causing us to make a lot more calls to
           afs_validate() to check the inode - and afs_validate() takes the
           RCU read lock each time to make a quick check (ie.
           afs_check_validity()). This is entirely for the purpose of checking
           cb_s_break to see if the server we're using reinitialised its list
           of callbacks - however this isn't a very common event, so most of
           the time we're taking this needlessly.
      
           Add a new cell-wide counter to count the number of
           reinitialisations done by any server and check that - and only if
           that changes, take the RCU read lock and check the server list (the
           server list may change, but the cell a file is part of won't).
      
         - Don't update vnode->cb_s_break and ->cb_v_break inside the validity
           checking loop. The cb_lock is done with read_seqretry, so we might
           go round the loop a second time after resetting those values - and
           that could cause someone else checking validity to miss something
           (I think).
      
        Also included are patches for fixes for some bugs encountered whilst
        debugging this:
      
         - Fix a leak of afs_read objects and fix a leak of keys hidden by
           that.
      
         - Fix a leak of pages that couldn't be added to extend a writeback.
      
         - Fix the maintenance of i_blocks when i_size is changed by a local
           write or a local dir edit"
      
      Link: https://bugzilla.kernel.org/show_bug.cgi?id=214217 [1]
      Link: https://lore.kernel.org/r/163111665183.283156.17200205573146438918.stgit@warthog.procyon.org.uk/ # v1
      Link: https://lore.kernel.org/r/163113612442.352844.11162345591911691150.stgit@warthog.procyon.org.uk/ # i_blocks patch
      
      * tag 'afs-fixes-20210913' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs:
        afs: Fix updating of i_blocks on file/dir extension
        afs: Fix corruption in reads at fpos 2G-4G from an OpenAFS server
        afs: Try to avoid taking RCU read lock when checking vnode validity
        afs: Fix mmap coherency vs 3rd-party changes
        afs: Fix incorrect triggering of sillyrename on 3rd-party invalidation
        afs: Add missing vnode validation checks
        afs: Fix page leak
        afs: Fix missing put on afs_read objects and missing get on the key therein
      d9fb6784
    • Linus Torvalds's avatar
      Merge tag '5.15-rc1-ksmbd' of git://git.samba.org/ksmbd · 707a63e9
      Linus Torvalds authored
      Pull ksmbd server fixes from Steve French:
       "Three ksmbd fixes, including an important security fix for path
        processing, and a buffer overflow check, and a trivial fix for
        incorrect header inclusion"
      
      * tag '5.15-rc1-ksmbd' of git://git.samba.org/ksmbd:
        ksmbd: add validation for FILE_FULL_EA_INFORMATION of smb2_get_info
        ksmbd: prevent out of share access
        ksmbd: transport_rdma: Don't include rwlock.h directly
      707a63e9
    • Linus Torvalds's avatar
      Merge tag '5.15-rc1-smb3' of git://git.samba.org/sfrench/cifs-2.6 · fdf50784
      Linus Torvalds authored
      Pull cifs client fixes from Steve French:
      
       - two deferred close fixes (for bugs found with xfstests 478 and 461)
      
       - a deferred close improvement in rename
      
       - two trivial fixes for incorrect Linux comment formatting of multiple
         cifs files (pointed out by automated kernel test robot and
         checkpatch)
      
      * tag '5.15-rc1-smb3' of git://git.samba.org/sfrench/cifs-2.6:
        cifs: Not to defer close on file when lock is set
        cifs: Fix soft lockup during fsstress
        cifs: Deferred close performance improvements
        cifs: fix incorrect kernel doc comments
        cifs: remove pathname for file from SPDX header
      fdf50784
    • Linus Torvalds's avatar
      Merge tag 'spi-fix-v5.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi · 4c17ca27
      Linus Torvalds authored
      Pull spi fixes from Mark BrownL
       "This contains a couple of fixes, one fix for handling of zero length
        transfers on Rockchip devices and a warning fix which will conflict
        with a version you did but cleans up some extra unneeded forward
        declarations as well which seems a bit neater"
      
      * tag 'spi-fix-v5.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi:
        spi: tegra20-slink: Declare runtime suspend and resume functions conditionally
        spi: rockchip: handle zero length transfers without timing out
      4c17ca27
    • Linus Torvalds's avatar
      Merge tag 'regulator-fix-v5.15-rc2' of... · 2ff59bad
      Linus Torvalds authored
      Merge tag 'regulator-fix-v5.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
      
      Pull regulator fixes from Mark Brown:
       "A couple of small device specific fixes that have been sent since the
        merge window, neither of which stands out particularly"
      
      * tag 'regulator-fix-v5.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
        regulator: max14577: Revert "regulator: max14577: Add proper module aliases strings"
        regulator: qcom-rpmh-regulator: fix pm8009-1 ldo7 resource name
      2ff59bad
    • Guenter Roeck's avatar
      drm/nouveau/nvkm: Replace -ENOSYS with -ENODEV · e8f71f89
      Guenter Roeck authored
      nvkm test builds fail with the following error.
      
        drivers/gpu/drm/nouveau/nvkm/engine/device/ctrl.c: In function 'nvkm_control_mthd_pstate_info':
        drivers/gpu/drm/nouveau/nvkm/engine/device/ctrl.c:60:35: error: overflow in conversion from 'int' to '__s8' {aka 'signed char'} changes value from '-251' to '5'
      
      The code builds on most architectures, but fails on parisc where ENOSYS
      is defined as 251.
      
      Replace the error code with -ENODEV (-19).  The actual error code does
      not really matter and is not passed to userspace - it just has to be
      negative.
      
      Fixes: 7238eca4 ("drm/nouveau: expose pstate selection per-power source in sysfs")
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Cc: David Airlie <airlied@linux.ie>
      Cc: Daniel Vetter <daniel@ffwll.ch>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      e8f71f89
    • Linus Torvalds's avatar
      sparc64: fix pci_iounmap() when CONFIG_PCI is not set · d8b1e10a
      Linus Torvalds authored
      Guenter reported [1] that the pci_iounmap() changes remain problematic,
      with sparc64 allnoconfig and tinyconfig still not building due to the
      header file changes and confusion with the arch-specific pci_iounmap()
      implementation.
      
      I'm pretty convinced that sparc should just use GENERIC_IOMAP instead of
      doing its own thing, since it turns out that the sparc64 version of
      pci_iounmap() is somewhat buggy (see [2]).  But in the meantime, this
      just fixes the build by avoiding the trivial re-definition of the empty
      case.
      
      Link: https://lore.kernel.org/lkml/20210920134424.GA346531@roeck-us.net/ [1]
      Link: https://lore.kernel.org/lkml/CAHk-=wgheheFx9myQyy5osh79BAazvmvYURAtub2gQtMvLrhqQ@mail.gmail.com/ [2]
      Reported-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Cc: David Miller <davem@davemloft.net>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      d8b1e10a
    • Linus Torvalds's avatar
      Linux 5.15-rc2 · e4e737bb
      Linus Torvalds authored
      e4e737bb
    • Linus Torvalds's avatar
      pci_iounmap'2: Electric Boogaloo: try to make sense of it all · 316e8d79
      Linus Torvalds authored
      Nathan Chancellor reports that the recent change to pci_iounmap in
      commit 9caea000 ("parisc: Declare pci_iounmap() parisc version only
      when CONFIG_PCI enabled") causes build errors on arm64.
      
      It took me about two hours to convince myself that I think I know what
      the logic of that mess of #ifdef's in the <asm-generic/io.h> header file
      really aim to do, and rewrite it to be easier to follow.
      
      Famous last words.
      
      Anyway, the code has now been lifted from that grotty header file into
      lib/pci_iomap.c, and has fairly extensive comments about what the logic
      is.  It also avoids indirecting through another confusing (and badly
      named) helper function that has other preprocessor config conditionals.
      
      Let's see what odd architecture did something else strange in this area
      to break things.  But my arm64 cross build is clean.
      
      Fixes: 9caea000 ("parisc: Declare pci_iounmap() parisc version only when CONFIG_PCI enabled")
      Reported-by: default avatarNathan Chancellor <nathan@kernel.org>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Guenter Roeck <linux@roeck-us.net>
      Cc: Ulrich Teichert <krypton@ulrich-teichert.org>
      Cc: James Bottomley <James.Bottomley@hansenpartnership.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      316e8d79
  7. 19 Sep, 2021 10 commits
    • Linus Torvalds's avatar
      Merge tag 'x86_urgent_for_v5.15_rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 20621d2f
      Linus Torvalds authored
      Pull x86 fixes from Borislav Petkov:
      
       - Prevent a infinite loop in the MCE recovery on return to user space,
         which was caused by a second MCE queueing work for the same page and
         thereby creating a circular work list.
      
       - Make kern_addr_valid() handle existing PMD entries, which are marked
         not present in the higher level page table, correctly instead of
         blindly dereferencing them.
      
       - Pass a valid address to sanitize_phys(). This was caused by the
         mixture of inclusive and exclusive ranges. memtype_reserve() expect
         'end' being exclusive, but sanitize_phys() wants it inclusive. This
         worked so far, but with end being the end of the physical address
         space the fail is exposed.
      
       - Increase the maximum supported GPIO numbers for 64bit. Newer SoCs
         exceed the previous maximum.
      
      * tag 'x86_urgent_for_v5.15_rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/mce: Avoid infinite loop for copy from user recovery
        x86/mm: Fix kern_addr_valid() to cope with existing but not present entries
        x86/platform: Increase maximum GPIO number for X86_64
        x86/pat: Pass valid address to sanitize_phys()
      20621d2f
    • Linus Torvalds's avatar
      Merge tag 'perf-urgent-2021-09-19' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · fec30362
      Linus Torvalds authored
      Pull perf event fix from Thomas Gleixner:
       "A single fix for the perf core where a value read with READ_ONCE() was
        checked and then reread which makes all the checks invalid. Reuse the
        already read value instead"
      
      * tag 'perf-urgent-2021-09-19' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        events: Reuse value read using READ_ONCE instead of re-reading it
      fec30362
    • Linus Torvalds's avatar
      Merge tag 'locking-urgent-2021-09-19' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · f5e29a26
      Linus Torvalds authored
      Pull locking fixes from Thomas Gleixner:
       "A set of updates for the RT specific reader/writer locking base code:
      
         - Make the fast path reader ordering guarantees correct.
      
         - Code reshuffling to make the fix simpler"
      
      [ This plays ugly games with atomic_add_return_release() because we
        don't have a plain atomic_add_release(), and should really be cleaned
        up, I think    - Linus ]
      
      * tag 'locking-urgent-2021-09-19' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        locking/rwbase: Take care of ordering guarantee for fastpath reader
        locking/rwbase: Extract __rwbase_write_trylock()
        locking/rwbase: Properly match set_and_save_state() to restore_state()
      f5e29a26
    • Linus Torvalds's avatar
      Merge tag 'powerpc-5.15-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · 62453a46
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
      
       - Fix crashes when scv (System Call Vectored) is used to make a syscall
         when a transaction is active, on Power9 or later.
      
       - Fix bad interactions between rfscv (Return-from scv) and Power9
         fake-suspend mode.
      
       - Fix crashes when handling machine checks in LPARs using the Hash MMU.
      
       - Partly revert a recent change to our XICS interrupt controller code,
         which broke the recently added Microwatt support.
      
      Thanks to Cédric Le Goater, Eirik Fuller, Ganesh Goudar, Gustavo Romero,
      Joel Stanley, Nicholas Piggin.
      
      * tag 'powerpc-5.15-2' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc/xics: Set the IRQ chip data for the ICS native backend
        powerpc/mce: Fix access error in mce handler
        KVM: PPC: Book3S HV: Tolerate treclaim. in fake-suspend mode changing registers
        powerpc/64s: system call rfscv workaround for TM bugs
        selftests/powerpc: Add scv versions of the basic TM syscall tests
        powerpc/64s: system call scv tabort fix for corrupt irq soft-mask state
      62453a46
    • Linus Torvalds's avatar
      Merge tag 'kbuild-fixes-v5.15' of... · 2f629969
      Linus Torvalds authored
      Merge tag 'kbuild-fixes-v5.15' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild
      
      Pull Kbuild fixes from Masahiro Yamada:
      
       - Fix bugs in checkkconfigsymbols.py
      
       - Fix missing sys import in gen_compile_commands.py
      
       - Fix missing FORCE warning for ARCH=sh builds
      
       - Fix -Wignored-optimization-argument warnings for Clang builds
      
       - Turn -Wignored-optimization-argument into an error in order to stop
         building instead of sprinkling warnings
      
      * tag 'kbuild-fixes-v5.15' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
        kbuild: Add -Werror=ignored-optimization-argument to CLANG_FLAGS
        x86/build: Do not add -falign flags unconditionally for clang
        kbuild: Fix comment typo in scripts/Makefile.modpost
        sh: Add missing FORCE prerequisites in Makefile
        gen_compile_commands: fix missing 'sys' package
        checkkconfigsymbols.py: Remove skipping of help lines in parse_kconfig_file
        checkkconfigsymbols.py: Forbid passing 'HEAD' to --commit
      2f629969
    • Linus Torvalds's avatar
      Merge tag 'perf-tools-fixes-for-v5.15-2021-09-18' of... · d94f3957
      Linus Torvalds authored
      Merge tag 'perf-tools-fixes-for-v5.15-2021-09-18' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux
      
      Pull perf tools fixes from Arnaldo Carvalho de Melo:
      
       - Fix ip display in 'perf script' when output type != attr->type.
      
       - Ignore deprecation warning when using libbpf'sg btf__get_from_id(),
         fixing the build with libbpf v0.6+.
      
       - Make use of FD() robust in libperf, fixing a segfault with 'perf stat
         --iostat list'.
      
       - Initialize addr_location:srcline pointer to NULL when resolving
         callchain addresses.
      
       - Fix fused instruction logic for assembly functions in 'perf
         annotate'.
      
      * tag 'perf-tools-fixes-for-v5.15-2021-09-18' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux:
        perf bpf: Ignore deprecation warning when using libbpf's btf__get_from_id()
        libperf evsel: Make use of FD robust.
        perf machine: Initialize srcline string member in add_location struct
        perf script: Fix ip display when type != attr->type
        perf annotate: Fix fused instr logic for assembly functions
      d94f3957
    • Linus Torvalds's avatar
      dmascc: use proper 'virt_to_bus()' rather than casting to 'int' · bc1abb9e
      Linus Torvalds authored
      The old dmascc driver depends on the legacy ISA_DMA_API, and blindly
      just casts the kernel virtual address to 'int' for set_dma_addr().
      
      That works only incidentally, and because the high bits of the address
      will be ignored anyway. And on 64-bit architectures it causes warnings.
      
      Admittedly, 64-bit architectures with ISA are basically dead - I think
      the only example of this is alpha, and nobody would ever use the dmascc
      driver there.  But hey, the fix is easy enough, the end result is
      cleaner, and it's yet another configuration that now builds without
      warnings.
      
      If somebody actually uses this driver on an alpha and this fixes it for
      you, please email me.  Because that is just incredibly bizarre.
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      bc1abb9e
    • Linus Torvalds's avatar
      alpha: enable GENERIC_PCI_IOMAP unconditionally · 4fef6115
      Linus Torvalds authored
      With the previous commit (9caea000: "parisc: Declare pci_iounmap()
      parisc version only when CONFIG_PCI enabled") we can now enable
      GENERIC_PCI_IOMAP unconditionally on alpha, and if PCI is not enabled we
      will just get the nice empty helper functions that allow mixed-bus
      drivers to build.
      
      Example driver: the old 3com/3c59x.c driver works with either the PCI or
      the EISA version of the 3x59x card, but wouldn't build in an EISA-only
      configuration because of missing pci_iomap() and pci_iounmap() dummy
      wrappers.
      
      Most of the other PCI infrastructure just becomes empty wrappers even
      without GENERIC_PCI_IOMAP, and it's not obvious that the pci_iomap
      functionality shouldn't do the same, but this works.
      
      Cc: Ulrich Teichert <krypton@ulrich-teichert.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      4fef6115
    • Helge Deller's avatar
      parisc: Declare pci_iounmap() parisc version only when CONFIG_PCI enabled · 9caea000
      Helge Deller authored
      Linus noticed odd declaration rules for pci_iounmap() in iomap.h and
      pci_iomap.h, where it dependend on either NO_GENERIC_PCI_IOPORT_MAP or
      GENERIC_IOMAP when CONFIG_PCI was disabled.
      
      Testing on parisc seems to indicate that we need pci_iounmap() only when
      CONFIG_PCI is enabled, so the declaration of pci_iounmap() can be moved
      cleanly into pci_iomap.h in sync with the declarations of pci_iomap().
      
      Link: https://lore.kernel.org/all/CAHk-=wjRrh98pZoQ+AzfWmsTZacWxTJKXZ9eKU2X_0+jM=O8nw@mail.gmail.com/Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      Suggested-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      Fixes: 97a29d59 ("[PARISC] fix compile break caused by iomap: make IOPORT/PCI mapping functions conditional")
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Guenter Roeck <linux@roeck-us.net>
      Cc: Ulrich Teichert <krypton@ulrich-teichert.org>
      Cc: James Bottomley <James.Bottomley@hansenpartnership.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      9caea000
    • Linus Torvalds's avatar
      Revert "drm/vc4: hdmi: Remove drm_encoder->crtc usage" · 31ad37bd
      Linus Torvalds authored
      This reverts commit 27da370e.
      
      Sudip Mukherjee reports that this broke pulseaudio with a NULL pointer
      dereference in vc4_hdmi_audio_prepare(), bisected it to this commit, and
      confirmed that a revert fixed the problem.
      
      Revert the problematic commit until fixed.
      
      Link: https://lore.kernel.org/all/CADVatmPB9-oKd=ypvj25UYysVo6EZhQ6bCM7EvztQBMyiZfAyw@mail.gmail.com/
      Link: https://lore.kernel.org/all/CADVatmN5EpRshGEPS_JozbFQRXg5w_8LFB3OMP1Ai-ghxd3w4g@mail.gmail.com/Reported-and-tested-by: default avatarSudip Mukherjee <sudipm.mukherjee@gmail.com>
      Cc: Maxime Ripard <maxime@cerno.tech>
      Cc: Emma Anholt <emma@anholt.net>
      Cc: Dave Airlie <airlied@gmail.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      31ad37bd