diff options
author | Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> | 2022-04-19 13:34:29 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-04-22 17:13:54 +0200 |
commit | 1e8ee51212b4876f1a8ca4b78d2499e2fc442cf3 (patch) | |
tree | 7172b6c12386e18f24f231fe7fde67539f6342e8 /drivers/s390/cio/cio.h | |
parent | 23d99baf9d729ca30b2fb6798a7b403a37bfb800 (diff) |
s390/cio: Use driver_set_override() instead of open-coding
Use a helper to set driver_override to the reduce amount of duplicated
code. Make the driver_override field const char, because it is not
modified by the core and it matches other subsystems.
Acked-by: Vineeth Vijayan <vneethv@linux.ibm.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20220419113435.246203-7-krzysztof.kozlowski@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/s390/cio/cio.h')
-rw-r--r-- | drivers/s390/cio/cio.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/s390/cio/cio.h b/drivers/s390/cio/cio.h index 1cb9daf9c645..fa8df50bb49e 100644 --- a/drivers/s390/cio/cio.h +++ b/drivers/s390/cio/cio.h @@ -103,7 +103,11 @@ struct subchannel { struct work_struct todo_work; struct schib_config config; u64 dma_mask; - char *driver_override; /* Driver name to force a match */ + /* + * Driver name to force a match. Do not set directly, because core + * frees it. Use driver_set_override() to set or clear it. + */ + const char *driver_override; } __attribute__ ((aligned(8))); DECLARE_PER_CPU_ALIGNED(struct irb, cio_irb); |