Skip to content

Commit 605cc30

Browse files
rddunlaptorvalds
authored andcommitted
zlib: move EXPORT_SYMBOL() and MODULE_LICENSE() out of dfltcc_syms.c
In commit 11fb479 ("zlib: export S390 symbols for zlib modules"), I added EXPORT_SYMBOL()s to dfltcc_inflate.c but then Mikhail said that these should probably be in dfltcc_syms.c with the other EXPORT_SYMBOL()s. However, that is contrary to the current kernel style, which places EXPORT_SYMBOL() immediately after the function that it applies to, so move all EXPORT_SYMBOL()s to their respective function locations and drop the dfltcc_syms.c file. Also move MODULE_LICENSE() from the deleted file to dfltcc.c. [[email protected]: remove dfltcc_syms.o from Makefile] Link: https://lkml.kernel.org/r/[email protected] Link: https://lkml.kernel.org/r/[email protected] Fixes: 11fb479 ("zlib: export S390 symbols for zlib modules") Signed-off-by: Randy Dunlap <[email protected]> Cc: Acked-by: Ilya Leoshkevich <[email protected]> Acked-by: Christian Borntraeger <[email protected]> Cc: Zaslonko Mikhail <[email protected]> Cc: Heiko Carstens <[email protected]> Cc: Vasily Gorbik <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent f0bb29e commit 605cc30

File tree

4 files changed

+9
-19
lines changed

4 files changed

+9
-19
lines changed

lib/zlib_dfltcc/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@
88

99
obj-$(CONFIG_ZLIB_DFLTCC) += zlib_dfltcc.o
1010

11-
zlib_dfltcc-objs := dfltcc.o dfltcc_deflate.o dfltcc_inflate.o dfltcc_syms.o
11+
zlib_dfltcc-objs := dfltcc.o dfltcc_deflate.o dfltcc_inflate.o

lib/zlib_dfltcc/dfltcc.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
// SPDX-License-Identifier: Zlib
22
/* dfltcc.c - SystemZ DEFLATE CONVERSION CALL support. */
33

4-
#include <linux/zutil.h>
4+
#include <linux/export.h>
5+
#include <linux/module.h>
56
#include "dfltcc_util.h"
67
#include "dfltcc.h"
78

@@ -53,3 +54,6 @@ void dfltcc_reset(
5354
dfltcc_state->dht_threshold = DFLTCC_DHT_MIN_SAMPLE_SIZE;
5455
dfltcc_state->param.ribm = DFLTCC_RIBM;
5556
}
57+
EXPORT_SYMBOL(dfltcc_reset);
58+
59+
MODULE_LICENSE("GPL");

lib/zlib_dfltcc/dfltcc_deflate.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
#include "dfltcc_util.h"
55
#include "dfltcc.h"
66
#include <asm/setup.h>
7+
#include <linux/export.h>
78
#include <linux/zutil.h>
89

910
/*
@@ -34,6 +35,7 @@ int dfltcc_can_deflate(
3435

3536
return 1;
3637
}
38+
EXPORT_SYMBOL(dfltcc_can_deflate);
3739

3840
static void dfltcc_gdht(
3941
z_streamp strm
@@ -277,3 +279,4 @@ int dfltcc_deflate(
277279
goto again; /* deflate() must use all input or all output */
278280
return 1;
279281
}
282+
EXPORT_SYMBOL(dfltcc_deflate);

lib/zlib_dfltcc/dfltcc_syms.c

Lines changed: 0 additions & 17 deletions
This file was deleted.

0 commit comments

Comments
 (0)