mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-05-24 10:39:52 +00:00

The pvrusb2 driver struct class logic was dynamically creating a class that should have just been static as it did not do anything special and was only a wrapper around a stock "struct class" implementation. Clean this all up by making a static struct class and modifying the code to correctly reference it. By doing so, lots of unneeded lines of code were removed, and #ifdef logic was cleaned up so that the .c files are not cluttered up with extra complexity following the proper kernel coding style. Cc: Mike Isely <isely@pobox.com> Cc: Mauro Carvalho Chehab <mchehab@kernel.org> Cc: linux-media@vger.kernel.org Reviewed-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Link: https://lore.kernel.org/r/20230329060132.2688621-1-gregkh@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
24 lines
613 B
C
24 lines
613 B
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
*
|
|
* Copyright (C) 2005 Mike Isely <isely@pobox.com>
|
|
*/
|
|
#ifndef __PVRUSB2_SYSFS_H
|
|
#define __PVRUSB2_SYSFS_H
|
|
|
|
#include <linux/list.h>
|
|
#include <linux/sysfs.h>
|
|
#include "pvrusb2-context.h"
|
|
|
|
#ifdef CONFIG_VIDEO_PVRUSB2_SYSFS
|
|
void pvr2_sysfs_class_create(void);
|
|
void pvr2_sysfs_class_destroy(void);
|
|
void pvr2_sysfs_create(struct pvr2_context *mp);
|
|
#else
|
|
static inline void pvr2_sysfs_class_create(void) { }
|
|
static inline void pvr2_sysfs_class_destroy(void) { }
|
|
static inline void pvr2_sysfs_create(struct pvr2_context *mp) { }
|
|
#endif
|
|
|
|
|
|
#endif /* __PVRUSB2_SYSFS_H */
|