Skip to content

Commit a8a0e2a

Browse files
committed
Merge tag 'driver-core-5.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
Pull driver core fixes from Greg KH: "Here are some small firmware/driver core/debugfs fixes for 5.7-rc3. The debugfs change is now possible as now the last users of debugfs_create_u32() have been fixed up in the different trees that got merged into 5.7-rc1, and I don't want it creeping back in. The firmware changes did cause a regression in linux-next, so the final patch here reverts part of that, re-exporting the symbol to resolve that issue. All of these patches, with the exception of the final one, have been in linux-next with only that one reported issue" * tag 'driver-core-5.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: firmware_loader: revert removal of the fw_fallback_config export debugfs: remove return value of debugfs_create_u32() firmware_loader: remove unused exports firmware: imx: fix compile-testing
2 parents 749f046 + 5a35770 commit a8a0e2a

File tree

5 files changed

+11
-25
lines changed

5 files changed

+11
-25
lines changed

Documentation/filesystems/debugfs.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,8 @@ created with any of::
7979
struct dentry *parent, u8 *value);
8080
void debugfs_create_u16(const char *name, umode_t mode,
8181
struct dentry *parent, u16 *value);
82-
struct dentry *debugfs_create_u32(const char *name, umode_t mode,
83-
struct dentry *parent, u32 *value);
82+
void debugfs_create_u32(const char *name, umode_t mode,
83+
struct dentry *parent, u32 *value);
8484
void debugfs_create_u64(const char *name, umode_t mode,
8585
struct dentry *parent, u64 *value);
8686

drivers/base/firmware_loader/fallback_table.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,4 @@ struct ctl_table firmware_config_table[] = {
4545
},
4646
{ }
4747
};
48-
EXPORT_SYMBOL_GPL(firmware_config_table);
4948
#endif

drivers/firmware/imx/Kconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ config IMX_DSP
1212

1313
config IMX_SCU
1414
bool "IMX SCU Protocol driver"
15-
depends on IMX_MBOX || COMPILE_TEST
15+
depends on IMX_MBOX
1616
help
1717
The System Controller Firmware (SCFW) is a low-level system function
1818
which runs on a dedicated Cortex-M core to provide power, clock, and
@@ -24,6 +24,6 @@ config IMX_SCU
2424

2525
config IMX_SCU_PD
2626
bool "IMX SCU Power Domain driver"
27-
depends on IMX_SCU || COMPILE_TEST
27+
depends on IMX_SCU
2828
help
2929
The System Controller Firmware (SCFW) based power domain driver.

fs/debugfs/file.c

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -506,20 +506,11 @@ DEFINE_DEBUGFS_ATTRIBUTE(fops_u32_wo, NULL, debugfs_u32_set, "%llu\n");
506506
* This function creates a file in debugfs with the given name that
507507
* contains the value of the variable @value. If the @mode variable is so
508508
* set, it can be read from, and written to.
509-
*
510-
* This function will return a pointer to a dentry if it succeeds. This
511-
* pointer must be passed to the debugfs_remove() function when the file is
512-
* to be removed (no automatic cleanup happens if your module is unloaded,
513-
* you are responsible here.) If an error occurs, ERR_PTR(-ERROR) will be
514-
* returned.
515-
*
516-
* If debugfs is not enabled in the kernel, the value ERR_PTR(-ENODEV) will
517-
* be returned.
518509
*/
519-
struct dentry *debugfs_create_u32(const char *name, umode_t mode,
520-
struct dentry *parent, u32 *value)
510+
void debugfs_create_u32(const char *name, umode_t mode, struct dentry *parent,
511+
u32 *value)
521512
{
522-
return debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u32,
513+
debugfs_create_mode_unsafe(name, mode, parent, value, &fops_u32,
523514
&fops_u32_ro, &fops_u32_wo);
524515
}
525516
EXPORT_SYMBOL_GPL(debugfs_create_u32);

include/linux/debugfs.h

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,8 @@ void debugfs_create_u8(const char *name, umode_t mode, struct dentry *parent,
103103
u8 *value);
104104
void debugfs_create_u16(const char *name, umode_t mode, struct dentry *parent,
105105
u16 *value);
106-
struct dentry *debugfs_create_u32(const char *name, umode_t mode,
107-
struct dentry *parent, u32 *value);
106+
void debugfs_create_u32(const char *name, umode_t mode, struct dentry *parent,
107+
u32 *value);
108108
void debugfs_create_u64(const char *name, umode_t mode, struct dentry *parent,
109109
u64 *value);
110110
struct dentry *debugfs_create_ulong(const char *name, umode_t mode,
@@ -250,12 +250,8 @@ static inline void debugfs_create_u8(const char *name, umode_t mode,
250250
static inline void debugfs_create_u16(const char *name, umode_t mode,
251251
struct dentry *parent, u16 *value) { }
252252

253-
static inline struct dentry *debugfs_create_u32(const char *name, umode_t mode,
254-
struct dentry *parent,
255-
u32 *value)
256-
{
257-
return ERR_PTR(-ENODEV);
258-
}
253+
static inline void debugfs_create_u32(const char *name, umode_t mode,
254+
struct dentry *parent, u32 *value) { }
259255

260256
static inline void debugfs_create_u64(const char *name, umode_t mode,
261257
struct dentry *parent, u64 *value) { }

0 commit comments

Comments
 (0)