Linux-Media Archive mirror
 help / color / mirror / Atom feed
From: Stefan Herdler <herdler@nurfuerspam.de>
To: hverkuil-cisco@xs4all.nl
Cc: linux-media@vger.kernel.org, smoch@web.de, tmn505@gmail.com,
	vinschen@redhat.com
Subject: [PATCH 21/21] media: av7110: coding style fixes: avoid_externs
Date: Tue,  7 May 2024 02:25:00 +0200	[thread overview]
Message-ID: <20240507002500.81867-22-herdler@nurfuerspam.de> (raw)
In-Reply-To: <20240507002500.81867-1-herdler@nurfuerspam.de>

This patch fixes the following checkpatch warnings:

CHECK:AVOID_EXTERNS: extern prototypes should be avoided in .h files

Removing unnecessary 'extern' declaration of function prototypes in
header files.

Signed-off-by: Stefan Herdler <herdler@nurfuerspam.de>
---
 drivers/staging/media/av7110/av7110.h       | 16 ++++-----
 drivers/staging/media/av7110/av7110_av.h    | 36 ++++++++++-----------
 drivers/staging/media/av7110/av7110_ca.h    | 12 +++----
 drivers/staging/media/av7110/av7110_hw.h    | 26 +++++++--------
 drivers/staging/media/av7110/av7110_ipack.h | 12 +++----
 5 files changed, 51 insertions(+), 51 deletions(-)

diff --git a/drivers/staging/media/av7110/av7110.h b/drivers/staging/media/av7110/av7110.h
index 403dbbba5..ec461fd18 100644
--- a/drivers/staging/media/av7110/av7110.h
+++ b/drivers/staging/media/av7110/av7110.h
@@ -284,8 +284,8 @@ struct av7110 {
 	int (*fe_set_frontend)(struct dvb_frontend *fe);
 };

-extern int ChangePIDs(struct av7110 *av7110, u16 vpid, u16 apid, u16 ttpid,
-		      u16 subpid, u16 pcrpid);
+int ChangePIDs(struct av7110 *av7110, u16 vpid, u16 apid, u16 ttpid,
+	       u16 subpid, u16 pcrpid);

 void av7110_ir_handler(struct av7110 *av7110, u32 ircom);
 int av7110_set_ir_config(struct av7110 *av7110);
@@ -298,12 +298,12 @@ void av7110_ir_exit(struct av7110 *av7110);
 #define MSP_WR_DSP 0x12
 #define MSP_RD_DSP 0x13

-extern int i2c_writereg(struct av7110 *av7110, u8 id, u8 reg, u8 val);
-extern u8 i2c_readreg(struct av7110 *av7110, u8 id, u8 reg);
-extern int msp_writereg(struct av7110 *av7110, u8 dev, u16 reg, u16 val);
+int i2c_writereg(struct av7110 *av7110, u8 id, u8 reg, u8 val);
+u8 i2c_readreg(struct av7110 *av7110, u8 id, u8 reg);
+int msp_writereg(struct av7110 *av7110, u8 dev, u16 reg, u16 val);

-extern int av7110_init_analog_module(struct av7110 *av7110);
-extern int av7110_init_v4l(struct av7110 *av7110);
-extern int av7110_exit_v4l(struct av7110 *av7110);
+int av7110_init_analog_module(struct av7110 *av7110);
+int av7110_init_v4l(struct av7110 *av7110);
+int av7110_exit_v4l(struct av7110 *av7110);

 #endif /* _AV7110_H_ */
diff --git a/drivers/staging/media/av7110/av7110_av.h b/drivers/staging/media/av7110/av7110_av.h
index f1c5c26c6..eebaf59c7 100644
--- a/drivers/staging/media/av7110/av7110_av.h
+++ b/drivers/staging/media/av7110/av7110_av.h
@@ -4,28 +4,28 @@

 struct av7110;

-extern int av7110_set_vidmode(struct av7110 *av7110,
-			      enum av7110_video_mode mode);
+int av7110_set_vidmode(struct av7110 *av7110,
+		       enum av7110_video_mode mode);

-extern int av7110_record_cb(struct dvb_filter_pes2ts *p2t, u8 *buf, size_t len);
-extern int av7110_pes_play(void *dest, struct dvb_ringbuffer *buf, int dlen);
-extern int av7110_write_to_decoder(struct dvb_demux_feed *feed, const u8 *buf, size_t len);
+int av7110_record_cb(struct dvb_filter_pes2ts *p2t, u8 *buf, size_t len);
+int av7110_pes_play(void *dest, struct dvb_ringbuffer *buf, int dlen);
+int av7110_write_to_decoder(struct dvb_demux_feed *feed, const u8 *buf, size_t len);

-extern int av7110_set_volume(struct av7110 *av7110, unsigned int volleft,
-			     unsigned int volright);
-extern int av7110_av_stop(struct av7110 *av7110, int av);
-extern int av7110_av_start_record(struct av7110 *av7110, int av,
-				  struct dvb_demux_feed *dvbdmxfeed);
-extern int av7110_av_start_play(struct av7110 *av7110, int av);
+int av7110_set_volume(struct av7110 *av7110, unsigned int volleft,
+		      unsigned int volright);
+int av7110_av_stop(struct av7110 *av7110, int av);
+int av7110_av_start_record(struct av7110 *av7110, int av,
+			   struct dvb_demux_feed *dvbdmxfeed);
+int av7110_av_start_play(struct av7110 *av7110, int av);

-extern void dvb_video_add_event(struct av7110 *av7110, struct video_event *event);
+void dvb_video_add_event(struct av7110 *av7110, struct video_event *event);

-extern void av7110_p2t_init(struct av7110_p2t *p, struct dvb_demux_feed *feed);
-extern void av7110_p2t_write(u8 const *buf, long length, u16 pid, struct av7110_p2t *p);
+void av7110_p2t_init(struct av7110_p2t *p, struct dvb_demux_feed *feed);
+void av7110_p2t_write(u8 const *buf, long length, u16 pid, struct av7110_p2t *p);

-extern int av7110_av_register(struct av7110 *av7110);
-extern void av7110_av_unregister(struct av7110 *av7110);
-extern int av7110_av_init(struct av7110 *av7110);
-extern void av7110_av_exit(struct av7110 *av7110);
+int av7110_av_register(struct av7110 *av7110);
+void av7110_av_unregister(struct av7110 *av7110);
+int av7110_av_init(struct av7110 *av7110);
+void av7110_av_exit(struct av7110 *av7110);

 #endif /* _AV7110_AV_H_ */
diff --git a/drivers/staging/media/av7110/av7110_ca.h b/drivers/staging/media/av7110/av7110_ca.h
index a6e3f2955..d3521944b 100644
--- a/drivers/staging/media/av7110/av7110_ca.h
+++ b/drivers/staging/media/av7110/av7110_ca.h
@@ -4,12 +4,12 @@

 struct av7110;

-extern void CI_handle(struct av7110 *av7110, u8 *data, u16 len);
-extern void ci_get_data(struct dvb_ringbuffer *cibuf, u8 *data, int len);
+void CI_handle(struct av7110 *av7110, u8 *data, u16 len);
+void ci_get_data(struct dvb_ringbuffer *cibuf, u8 *data, int len);

-extern int av7110_ca_register(struct av7110 *av7110);
-extern void av7110_ca_unregister(struct av7110 *av7110);
-extern int av7110_ca_init(struct av7110* av7110);
-extern void av7110_ca_exit(struct av7110* av7110);
+int av7110_ca_register(struct av7110 *av7110);
+void av7110_ca_unregister(struct av7110 *av7110);
+int av7110_ca_init(struct av7110 *av7110);
+void av7110_ca_exit(struct av7110 *av7110);

 #endif /* _AV7110_CA_H_ */
diff --git a/drivers/staging/media/av7110/av7110_hw.h b/drivers/staging/media/av7110/av7110_hw.h
index c13b8c479..d4579f411 100644
--- a/drivers/staging/media/av7110/av7110_hw.h
+++ b/drivers/staging/media/av7110/av7110_hw.h
@@ -357,22 +357,22 @@ enum av7110_command_type {
 #define DEBI_DONE_LINE		1
 #define ARM_IRQ_LINE		0

-extern int av7110_bootarm(struct av7110 *av7110);
-extern int av7110_firmversion(struct av7110 *av7110);
+int av7110_bootarm(struct av7110 *av7110);
+int av7110_firmversion(struct av7110 *av7110);
 #define FW_CI_LL_SUPPORT(arm_app) ((arm_app) & 0x80000000)
 #define FW_4M_SDRAM(arm_app)      ((arm_app) & 0x40000000)
 #define FW_VERSION(arm_app)	  ((arm_app) & 0x0000FFFF)

-extern int av7110_wait_msgstate(struct av7110 *av7110, u16 flags);
-extern int av7110_fw_cmd(struct av7110 *av7110, int type, int com, int num, ...);
-extern int av7110_fw_request(struct av7110 *av7110, u16 *request_buf,
-			     int request_buf_len, u16 *reply_buf, int reply_buf_len);
+int av7110_wait_msgstate(struct av7110 *av7110, u16 flags);
+int av7110_fw_cmd(struct av7110 *av7110, int type, int com, int num, ...);
+int av7110_fw_request(struct av7110 *av7110, u16 *request_buf,
+		      int request_buf_len, u16 *reply_buf, int reply_buf_len);

 /* DEBI (saa7146 data extension bus interface) access */
-extern int av7110_debiwrite(struct av7110 *av7110, u32 config,
-			    int addr, u32 val, unsigned int count);
-extern u32 av7110_debiread(struct av7110 *av7110, u32 config,
-			   int addr, unsigned int count);
+int av7110_debiwrite(struct av7110 *av7110, u32 config,
+		     int addr, u32 val, unsigned int count);
+u32 av7110_debiread(struct av7110 *av7110, u32 config,
+		    int addr, unsigned int count);

 /* DEBI during interrupt */
 /* single word writes */
@@ -473,11 +473,11 @@ static inline int Set22K(struct av7110 *av7110, int state)
 	return av7110_fw_cmd(av7110, COMTYPE_AUDIODAC, (state ? ON22K : OFF22K), 0);
 }

-extern int av7110_diseqc_send(struct av7110 *av7110, int len, u8 *msg, unsigned long burst);
+int av7110_diseqc_send(struct av7110 *av7110, int len, u8 *msg, unsigned long burst);

 #ifdef CONFIG_DVB_AV7110_OSD
-extern int av7110_osd_cmd(struct av7110 *av7110, osd_cmd_t *dc);
-extern int av7110_osd_capability(struct av7110 *av7110, osd_cap_t *cap);
+int av7110_osd_cmd(struct av7110 *av7110, osd_cmd_t *dc);
+int av7110_osd_capability(struct av7110 *av7110, osd_cap_t *cap);
 #endif /* CONFIG_DVB_AV7110_OSD */

 #endif /* _AV7110_HW_H_ */
diff --git a/drivers/staging/media/av7110/av7110_ipack.h b/drivers/staging/media/av7110/av7110_ipack.h
index 943ec899b..55296421d 100644
--- a/drivers/staging/media/av7110/av7110_ipack.h
+++ b/drivers/staging/media/av7110/av7110_ipack.h
@@ -2,12 +2,12 @@
 #ifndef _AV7110_IPACK_H_
 #define _AV7110_IPACK_H_

-extern int av7110_ipack_init(struct ipack *p, int size,
-			     void (*func)(u8 *buf,  int size, void *priv));
+int av7110_ipack_init(struct ipack *p, int size,
+		      void (*func)(u8 *buf,  int size, void *priv));

-extern void av7110_ipack_reset(struct ipack *p);
-extern int  av7110_ipack_instant_repack(const u8 *buf, int count, struct ipack *p);
-extern void av7110_ipack_free(struct ipack * p);
-extern void av7110_ipack_flush(struct ipack *p);
+void av7110_ipack_reset(struct ipack *p);
+int  av7110_ipack_instant_repack(const u8 *buf, int count, struct ipack *p);
+void av7110_ipack_free(struct ipack *p);
+void av7110_ipack_flush(struct ipack *p);

 #endif
--
2.34.0


      parent reply	other threads:[~2024-05-07  0:27 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-07  0:24 [PATCH 00/21] media: av7110: make chackpatch happier Stefan Herdler
2024-05-07  0:24 ` [PATCH 01/21] media: av7110: remove old documentation files Stefan Herdler
2024-05-07  0:24 ` [PATCH 02/21] media: av7110: remove budget-patch driver Stefan Herdler
2024-05-07  0:24 ` [PATCH 03/21] media: sp8870: coding style fixes: whitespace Stefan Herdler
2024-05-07  0:24 ` [PATCH 04/21] media: sp8870: coding style fixes: newline, comments and braces Stefan Herdler
2024-05-07  0:24 ` [PATCH 05/21] media: sp8870: coding style fixes: miscellaneous Stefan Herdler
2024-05-07  0:24 ` [PATCH 06/21] media: sp8870: coding style fixes: logging Stefan Herdler
2024-05-07  0:24 ` [PATCH 07/21] media: av7110: coding style fixes: pointer_location Stefan Herdler
2024-05-07  0:24 ` [PATCH 08/21] media: av7110: coding style fixes: blank lines Stefan Herdler
2024-05-07  0:24 ` [PATCH 09/21] media: av7110: coding style fixes: whitespace Stefan Herdler
2024-05-07  0:24 ` [PATCH 10/21] media: av7110: coding style fixes: newline Stefan Herdler
2024-05-07  0:24 ` [PATCH 11/21] media: av7110: coding style fixes: whitespace (strict) Stefan Herdler
2024-05-07  0:24 ` [PATCH 12/21] media: av7110: coding style fixes: comments Stefan Herdler
2024-05-07  0:24 ` [PATCH 13/21] media: av7110: coding style fixes: braces Stefan Herdler
2024-05-07  0:24 ` [PATCH 14/21] media: av7110: coding style fixes: assignments Stefan Herdler
2024-05-07  0:24 ` [PATCH 15/21] media: av7110: coding style fixes: comparsations Stefan Herdler
2024-05-07  0:24 ` [PATCH 16/21] media: av7110: coding style fixes: sizeof Stefan Herdler
2024-05-07  0:24 ` [PATCH 17/21] media: av7110: coding style fixes: variable types Stefan Herdler
2024-05-07  0:24 ` [PATCH 18/21] media: av7110: coding style fixes: miscellaneous Stefan Herdler
2024-05-07  0:24 ` [PATCH 19/21] media: av7110: coding style fixes: deep_indentation Stefan Herdler
2024-05-07  0:24 ` [PATCH 20/21] media: av7110: coding style fixes: logging Stefan Herdler
2024-05-07  0:25 ` Stefan Herdler [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240507002500.81867-22-herdler@nurfuerspam.de \
    --to=herdler@nurfuerspam.de \
    --cc=hverkuil-cisco@xs4all.nl \
    --cc=linux-media@vger.kernel.org \
    --cc=smoch@web.de \
    --cc=tmn505@gmail.com \
    --cc=vinschen@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).