diff mbox

[01/10] ASoC: fsl_ssi: Remove unused struct device

Message ID 1512420403-10164-2-git-send-email-nicoleotsuka@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Nicolin Chen Dec. 4, 2017, 8:46 p.m. UTC
struct device is defined in system level header files any way.
As long as fsl_ssi.h is included after those header files, it
should be safe to remove this line.

Signed-off-by: Nicolin Chen <nicoleotsuka@gmail.com>
---
 sound/soc/fsl/fsl_ssi.h | 2 --
 1 file changed, 2 deletions(-)

Comments

Mark Brown Dec. 5, 2017, 1:04 p.m. UTC | #1
On Mon, Dec 04, 2017 at 12:46:34PM -0800, Nicolin Chen wrote:
> struct device is defined in system level header files any way.
> As long as fsl_ssi.h is included after those header files, it
> should be safe to remove this line.

It's better practice to either directly include those headers or have a
forward declaration like this, it means there's no way things can go
wrong.
Nicolin Chen Dec. 5, 2017, 7:39 p.m. UTC | #2
On Tue, Dec 05, 2017 at 01:04:46PM +0000, Mark Brown wrote:
> On Mon, Dec 04, 2017 at 12:46:34PM -0800, Nicolin Chen wrote:
> > struct device is defined in system level header files any way.
> > As long as fsl_ssi.h is included after those header files, it
> > should be safe to remove this line.
> 
> It's better practice to either directly include those headers or have a
> forward declaration like this, it means there's no way things can go
> wrong.

I see. I will drop this patch then.
diff mbox

Patch

diff --git a/sound/soc/fsl/fsl_ssi.h b/sound/soc/fsl/fsl_ssi.h
index 5065105..5cf56d2 100644
--- a/sound/soc/fsl/fsl_ssi.h
+++ b/sound/soc/fsl/fsl_ssi.h
@@ -206,8 +206,6 @@ 
 #define CCSR_SSI_SACNT_AC97EN		0x00000001
 
 
-struct device;
-
 #if IS_ENABLED(CONFIG_DEBUG_FS)
 
 struct fsl_ssi_dbg {