linux-stable/kernel/dma
Randy Dunlap 80e4390981 dma-debug: fix return value of __setup handlers
When valid kernel command line parameters
  dma_debug=off dma_debug_entries=100
are used, they are reported as Unknown parameters and added to init's
environment strings, polluting it.

  Unknown kernel command line parameters "BOOT_IMAGE=/boot/bzImage-517rc5
    dma_debug=off dma_debug_entries=100", will be passed to user space.

and

 Run /sbin/init as init process
   with arguments:
     /sbin/init
   with environment:
     HOME=/
     TERM=linux
     BOOT_IMAGE=/boot/bzImage-517rc5
     dma_debug=off
     dma_debug_entries=100

Return 1 from these __setup handlers to indicate that the command line
option has been handled.

Fixes: 59d3daafa1 ("dma-debug: add kernel command line parameters")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Reported-by: Igor Zhbanov <i.zhbanov@omprussia.ru>
Link: lore.kernel.org/r/64644a2f-4a20-bab3-1e15-3b2cdd0defe3@omprussia.ru
Cc: Joerg Roedel <joro@8bytes.org>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: iommu@lists.linux-foundation.org
Cc: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
2022-03-03 14:01:45 +03:00
..
coherent.c dma-mapping: use 'bitmap_zalloc()' when applicable 2021-10-27 08:20:09 +02:00
contiguous.c dma-contiguous: fix a typo error in a comment 2020-11-27 10:33:42 +01:00
debug.c dma-debug: fix return value of __setup handlers 2022-03-03 14:01:45 +03:00
debug.h dma-debug: teach add_dma_entry() about DMA_ATTR_SKIP_CPU_SYNC 2021-10-18 12:46:45 +02:00
direct.c dma-mapping: remove CONFIG_DMA_REMAP 2022-03-03 14:00:57 +03:00
direct.h swiotlb: Use is_swiotlb_force_bounce for swiotlb data bouncing 2021-07-13 20:04:43 -04:00
dummy.c dma-mapping: return error code from dma_dummy_map_sg() 2021-08-09 17:13:06 +02:00
Kconfig dma-mapping: remove CONFIG_DMA_REMAP 2022-03-03 14:00:57 +03:00
Makefile dma-mapping: remove CONFIG_DMA_REMAP 2022-03-03 14:00:57 +03:00
map_benchmark.c dma-mapping: benchmark: Add support for multi-pages map/unmap 2021-04-02 16:41:08 +02:00
mapping.c arm64 updates for 5.16 2021-11-01 16:33:53 -07:00
ops_helpers.c dma-mapping: handle vmalloc addresses in dma_common_{mmap,get_sgtable} 2021-07-16 11:30:26 +02:00
pool.c dma/pool: create dma atomic pool only if dma zone has managed pages 2022-01-15 16:30:29 +02:00
remap.c kernel/dma: remove unnecessary unmap_kernel_range 2021-04-30 11:20:40 -07:00
swiotlb.c swiotlb: simplify array allocation 2022-01-26 17:21:19 +01:00