OpenCloudOS-Kernel/drivers/spi
Petr Mladek 3989144f86 kthread: kthread worker API cleanup
A good practice is to prefix the names of functions by the name
of the subsystem.

The kthread worker API is a mix of classic kthreads and workqueues.  Each
worker has a dedicated kthread.  It runs a generic function that process
queued works.  It is implemented as part of the kthread subsystem.

This patch renames the existing kthread worker API to use
the corresponding name from the workqueues API prefixed by
kthread_:

__init_kthread_worker()		-> __kthread_init_worker()
init_kthread_worker()		-> kthread_init_worker()
init_kthread_work()		-> kthread_init_work()
insert_kthread_work()		-> kthread_insert_work()
queue_kthread_work()		-> kthread_queue_work()
flush_kthread_work()		-> kthread_flush_work()
flush_kthread_worker()		-> kthread_flush_worker()

Note that the names of DEFINE_KTHREAD_WORK*() macros stay
as they are. It is common that the "DEFINE_" prefix has
precedence over the subsystem names.

Note that INIT() macros and init() functions use different
naming scheme. There is no good solution. There are several
reasons for this solution:

  + "init" in the function names stands for the verb "initialize"
    aka "initialize worker". While "INIT" in the macro names
    stands for the noun "INITIALIZER" aka "worker initializer".

  + INIT() macros are used only in DEFINE() macros

  + init() functions are used close to the other kthread()
    functions. It looks much better if all the functions
    use the same scheme.

  + There will be also kthread_destroy_worker() that will
    be used close to kthread_cancel_work(). It is related
    to the init() function. Again it looks better if all
    functions use the same naming scheme.

  + there are several precedents for such init() function
    names, e.g. amd_iommu_init_device(), free_area_init_node(),
    jump_label_init_type(),  regmap_init_mmio_clk(),

  + It is not an argument but it was inconsistent even before.

[arnd@arndb.de: fix linux-next merge conflict]
 Link: http://lkml.kernel.org/r/20160908135724.1311726-1-arnd@arndb.de
Link: http://lkml.kernel.org/r/1470754545-17632-3-git-send-email-pmladek@suse.com
Suggested-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Petr Mladek <pmladek@suse.com>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
Cc: Josh Triplett <josh@joshtriplett.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Jiri Kosina <jkosina@suse.cz>
Cc: Borislav Petkov <bp@suse.de>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-10-11 15:06:33 -07:00
..
Kconfig Merge remote-tracking branches 'spi/topic/rspi', 'spi/topic/sc18is602', 'spi/topic/sh-msiof', 'spi/topic/spidev-test' and 'spi/topic/st-ssc4' into spi-next 2016-09-30 09:14:18 -07:00
Makefile Merge remote-tracking branches 'spi/topic/octeon', 'spi/topic/pic32-sqi', 'spi/topic/pxa2xx' and 'spi/topic/qup' into spi-next 2016-09-30 09:14:14 -07:00
spi-adi-v3.c
spi-altera.c
spi-ath79.c spi: ath79: simplify iomem resource mapping 2015-09-30 20:33:29 +01:00
spi-atmel.c spi: atmel: fix gpio chip-select in case of non-DT platform 2016-01-28 23:25:54 +01:00
spi-au1550.c spi: au1550: Simplify au1550_spi_setupxfer() 2015-09-16 20:54:54 +01:00
spi-axi-spi-engine.c spi: Drop duplicate code to set master->dev.parent 2016-04-26 11:56:09 +01:00
spi-bcm-qspi.c spi: iproc-qspi: Add Broadcom iProc SoCs support 2016-09-24 20:03:25 +01:00
spi-bcm-qspi.h spi: iproc-qspi: Add Broadcom iProc SoCs support 2016-09-24 20:03:25 +01:00
spi-bcm53xx.c spi: bcm53xx: add spi_flash_read callback for MMIO-based reads 2016-04-18 13:53:46 +01:00
spi-bcm53xx.h
spi-bcm63xx-hsspi.c spi/bcm63xx-hsspi: add support for dual spi read/write 2015-08-25 17:33:49 +01:00
spi-bcm63xx.c Merge remote-tracking branches 'spi/topic/bcm63xx', 'spi/topic/butterfly', 'spi/topic/cadence' and 'spi/topic/davinci' into spi-next 2016-01-11 16:48:30 +00:00
spi-bcm2835.c spi: bcm2835: Remove unnecessary workaround to call gpio_set_value 2016-02-15 20:43:39 +00:00
spi-bcm2835aux.c Merge remote-tracking branches 'spi/topic/acpi', 'spi/topic/axi-engine', 'spi/topic/bcm2835' and 'spi/topic/bcm2835aux' into spi-next 2016-03-11 14:28:25 +07:00
spi-bfin-sport.c spi: spi-bfin-sport: Remove deprecated create_singlethread_workqueue 2016-07-03 14:24:31 +02:00
spi-bfin5xx.c spi: spi-bfin5xx: Remove deprecated create_singlethread_workqueue 2016-07-03 14:14:31 +02:00
spi-bitbang-txrx.h spi: Fix regression in spi-bitbang-txrx.h 2015-07-29 15:01:07 +01:00
spi-bitbang.c spi: bitbang: switch to the generic implementation of transfer_one_message 2015-10-05 14:55:56 +01:00
spi-brcmstb-qspi.c spi: brcmstb-qspi: Broadcom settop platform driver 2016-09-14 18:03:32 +01:00
spi-butterfly.c spi: butterfly: use new parport device model 2015-12-02 19:38:16 +00:00
spi-cadence.c spi: cadence: mark pm functions __maybe_unused 2016-04-18 10:58:49 +01:00
spi-cavium-octeon.c spi: octeon: Split driver into Octeon specific and common parts 2016-07-24 21:54:29 +01:00
spi-cavium-thunderx.c spi: spi-cavium-thunderx: Add missing clk_disable_unprepare() 2016-08-24 12:37:43 +01:00
spi-cavium.c spi: octeon: Split driver into Octeon specific and common parts 2016-07-24 21:54:29 +01:00
spi-cavium.h spi: octeon: Add ThunderX driver 2016-08-19 16:24:39 +01:00
spi-clps711x.c spi: clps711x: Driver refactor 2016-07-07 11:44:43 +02:00
spi-coldfire-qspi.c spi: spi-coldfire-qspi: enable RuntimePM before registering to the core 2015-10-12 17:02:08 +01:00
spi-davinci.c spi: davinci: Use dma_request_chan() for requesting DMA channel 2016-04-29 18:15:15 +01:00
spi-dln2.c spi: Drop duplicate code to set master->dev.parent 2016-04-26 11:56:09 +01:00
spi-dw-mid.c spi: dw-mid: switch to new dmaengine_terminate_* API 2016-02-05 17:41:49 +00:00
spi-dw-mmio.c spi: dw-mmio: remove message which is handled by core 2016-02-05 17:41:49 +00:00
spi-dw-pci.c spi: dw-pci: Spelling s/paltforms/platforms/g 2016-05-11 18:26:19 +01:00
spi-dw.c spi: dw: round up result of calculation for clock divider 2016-09-12 19:59:08 +01:00
spi-dw.h spi: dw: fix multiple slaves with different baudrates 2016-09-06 11:53:50 +01:00
spi-efm32.c
spi-ep93xx.c spi: spi-ep93xx: Fix the PTR_ERR() argument 2016-05-24 16:54:50 +01:00
spi-falcon.c Merge remote-tracking branches 'spi/topic/falcon', 'spi/topic/fsf', 'spi/topic/fsl', 'spi/topic/fsl-dspi' and 'spi/topic/gpio' into spi-next 2015-02-08 11:16:46 +08:00
spi-fsl-cpm.c QE: Move QE from arch/powerpc to drivers/soc 2015-12-22 17:12:56 -06:00
spi-fsl-cpm.h
spi-fsl-dspi.c spi: spi-fsl-dspi: Drop extra spi_master_put in device remove function 2016-08-22 17:45:22 +01:00
spi-fsl-espi.c spi: fsl-espi: improve return value handling in fsl_espi_probe 2016-09-24 19:48:32 +01:00
spi-fsl-lib.c spi: fsl-(e)spi: simplify cleanup code 2015-08-28 18:15:18 +01:00
spi-fsl-lib.h spi: fsl-espi: align register access with other drivers 2016-09-14 18:24:47 +01:00
spi-fsl-spi.c spi: fsl-(e)spi: Fix checking return value of devm_ioremap_resource 2015-08-30 12:14:36 +01:00
spi-fsl-spi.h
spi-gpio.c Merge remote-tracking branches 'spi/topic/falcon', 'spi/topic/fsf', 'spi/topic/fsl', 'spi/topic/fsl-dspi' and 'spi/topic/gpio' into spi-next 2015-02-08 11:16:46 +08:00
spi-img-spfi.c spi: img-spfi: Remove spi_master_put in img_spfi_remove() 2016-07-27 19:00:16 +01:00
spi-imx.c spi: imx: fix error return code in spi_imx_probe() 2016-09-28 09:50:55 -07:00
spi-iproc-qspi.c spi: iproc-qspi: Add Broadcom iProc SoCs support 2016-09-24 20:03:25 +01:00
spi-jcore.c spi: jcore: remove unnecessary platform_set_drvdata() 2016-08-09 10:40:05 +01:00
spi-lm70llp.c spi: lm70llp: remove printk 2015-12-07 20:09:09 +00:00
spi-loopback-test.c spi: loopback-test: mark rx_ranges_cmp() static 2016-09-01 20:54:54 +01:00
spi-lp8841-rtc.c spi: lp-8841: return correct error code from probe 2016-02-26 11:06:38 +09:00
spi-meson-spifc.c spi: meson: Add GXBB compatible 2016-09-12 20:11:39 +01:00
spi-mpc52xx-psc.c spi: spi-mpc52xx-psc: Remove deprecated create_singlethread_workqueue 2016-07-03 14:23:25 +02:00
spi-mpc52xx.c
spi-mpc512x-psc.c spi: mpc512x: Call mpc512x_psc_spi_transfer_setup() unconditionally 2015-09-17 12:33:31 +01:00
spi-mt65xx.c spi: mediatek: remove spi_master_put in mtk_spi_remove() 2016-07-27 19:00:16 +01:00
spi-mxs.c spi: mxs: cleanup wait_for_completion return handling 2015-02-05 18:04:57 +00:00
spi-nuc900.c
spi-oc-tiny.c spi: oc-tiny: Use of_property_read_u32 instead of open-coding it 2015-09-16 19:16:01 +01:00
spi-omap-100k.c spi: omap-100k: Rely on validations done by spi core 2015-09-17 12:34:20 +01:00
spi-omap-uwire.c spi: omap-uwire: Remove needless bits_per_word and speed_hz tests 2015-09-17 12:33:58 +01:00
spi-omap2-mcspi.c spi: omap2-mcspi: Use the SPI framework to handle DMA mapping 2016-07-08 10:48:02 +02:00
spi-orion.c spi: orion: Fix return value check in orion_spi_probe() 2016-06-13 16:36:40 +01:00
spi-pic32-sqi.c spi: pic32-sqi: use list_move_tail and list_move 2016-08-08 11:56:40 +01:00
spi-pic32.c spi: pic32: fixup wait_for_completion_timeout return handling 2016-07-24 21:49:16 +01:00
spi-pl022.c spi: pl022: Remove obsolete struct pl022 members from kerneldoc 2016-02-17 12:08:55 +00:00
spi-ppc4xx.c spi: bitbang: Replace spinlock by mutex 2015-09-17 12:13:40 +01:00
spi-pxa2xx-dma.c spi: pxa2xx: Remove pointer to chip data from driver data 2016-09-12 20:01:27 +01:00
spi-pxa2xx-pci.c spi: pxa2xx-pci: fix ACPI-based enumeration of SPI devices 2016-08-24 12:20:03 +01:00
spi-pxa2xx.c spi: pxa2xx: Fix build error because of missing header 2016-09-29 11:00:41 -07:00
spi-pxa2xx.h spi: pxa2xx: Add support for GPIO descriptor chip selects 2016-09-26 09:11:14 -07:00
spi-qup.c Merge remote-tracking branches 'spi/topic/octeon', 'spi/topic/pic32-sqi', 'spi/topic/pxa2xx' and 'spi/topic/qup' into spi-next 2016-09-30 09:14:14 -07:00
spi-rb4xx.c spi: rb4xx: Fix checking return value of devm_ioremap_resource() 2015-05-01 17:35:54 +01:00
spi-rockchip.c Merge remote-tracking branches 'spi/topic/pxa2xx', 'spi/topic/rockchip', 'spi/topic/s3c64xx', 'spi/topic/sh' and 'spi/topic/sh-msiof' into spi-next 2016-07-24 22:08:25 +01:00
spi-rspi.c spi: rspi: Increase accuracy of bit rate for RZ 2016-08-08 11:56:46 +01:00
spi-s3c24xx-fiq.S
spi-s3c24xx-fiq.h
spi-s3c24xx.c spi: bitbang: Replace spinlock by mutex 2015-09-17 12:13:40 +01:00
spi-s3c64xx.c spi: s3c64xx: restore removed comments 2016-07-14 17:28:32 +01:00
spi-sc18is602.c spi: sc18is602: Change gpiod_set_value to gpiod_set_value_cansleep 2016-09-29 11:01:36 -07:00
spi-sh-hspi.c
spi-sh-msiof.c spi: sh-msiof: Avoid invalid clock generator parameters 2016-08-05 11:46:07 +01:00
spi-sh-sci.c
spi-sh.c spi: spi-sh: Remove deprecated create_singlethread_workqueue 2016-07-11 19:32:38 +01:00
spi-sirf.c spi: sirf: add the reset for USP-based SPI 2015-05-26 11:39:16 +01:00
spi-st-ssc4.c spi: st-ssc4: Fix misuse of devm_gpio_request/devm_gpio_free APIs 2016-09-14 16:05:35 +01:00
spi-sun4i.c Merge remote-tracking branches 'spi/topic/spidev', 'spi/topic/sunxi', 'spi/topic/ti-qspi', 'spi/topic/topcliff-pch' and 'spi/topic/txx9' into spi-next 2016-07-24 22:08:27 +01:00
spi-sun6i.c Merge remote-tracking branches 'spi/topic/spidev', 'spi/topic/sunxi', 'spi/topic/ti-qspi', 'spi/topic/topcliff-pch' and 'spi/topic/txx9' into spi-next 2016-07-24 22:08:27 +01:00
spi-tegra20-sflash.c
spi-tegra20-slink.c
spi-tegra114.c
spi-test.h spi: loopback: added additional non-power of 2 transfer lengthes 2015-12-13 20:10:15 +00:00
spi-ti-qspi.c spi: spi-ti-qspi: Add DMA support for QSPI mmap read 2016-08-17 12:24:28 +01:00
spi-tle62x0.c spi: Drop owner assignment from spi_drivers 2015-10-28 10:30:17 +09:00
spi-topcliff-pch.c spi: spi-topcliff-pch: Remove deprecated create_singlethread_workqueue 2016-07-11 19:32:26 +01:00
spi-txx9.c spi: spi-txx9: Add missing clock (un)prepare calls for CCF 2016-08-18 19:10:39 +01:00
spi-xcomm.c spi: xcomm: Export I2C module alias information 2015-07-31 18:14:57 +01:00
spi-xilinx.c spi: xilinx: Return IRQ_NONE if no interrupts were detected 2016-07-15 11:45:00 +01:00
spi-xlp.c spi: xlp: Add ACPI support for Vulcan SPI controller 2016-08-09 15:25:43 +01:00
spi-xtensa-xtfpga.c spi: xtensa-xtfpga: fix register endianness 2015-09-22 09:30:10 -07:00
spi-zynqmp-gqspi.c spi: zynqmp: disable clocks in error paths 2016-05-04 14:21:03 +01:00
spi.c kthread: kthread worker API cleanup 2016-10-11 15:06:33 -07:00
spidev.c spi: spidev: Add ACPI probing support 2016-07-04 16:28:52 +02:00