firmware: wrap FW_OPT_* into an enum

This should let us associate enum kdoc to these values.
While at it, kdocify the fw_opt.

Signed-off-by: Andres Rodriguez <andresx7@gmail.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Acked-by: Luis R. Rodriguez <mcgrof@kernel.org>
[mcgrof: coding style fixes, merge kdoc with enum move]
Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Andres Rodriguez 2018-05-10 13:08:37 -07:00 committed by Greg Kroah-Hartman
parent 84d0c27d62
commit eb33eb0492
4 changed files with 42 additions and 19 deletions

View file

@ -443,7 +443,7 @@ static int fw_add_devm_name(struct device *dev, const char *name)
#endif
int assign_fw(struct firmware *fw, struct device *device,
unsigned int opt_flags)
enum fw_opt opt_flags)
{
struct fw_priv *fw_priv = fw->priv;
int ret;
@ -558,7 +558,7 @@ static void fw_abort_batch_reqs(struct firmware *fw)
static int
_request_firmware(const struct firmware **firmware_p, const char *name,
struct device *device, void *buf, size_t size,
unsigned int opt_flags)
enum fw_opt opt_flags)
{
struct firmware *fw = NULL;
int ret;
@ -734,7 +734,7 @@ struct firmware_work {
struct device *device;
void *context;
void (*cont)(const struct firmware *fw, void *context);
unsigned int opt_flags;
enum fw_opt opt_flags;
};
static void request_firmware_work_func(struct work_struct *work)