]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
media: av7110: coding style fixes: avoid_externs
authorStefan Herdler <herdler@nurfuerspam.de>
Tue, 7 May 2024 00:25:00 +0000 (02:25 +0200)
committerHans Verkuil <hverkuil-cisco@xs4all.nl>
Tue, 4 Jun 2024 14:19:56 +0000 (16:19 +0200)
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>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
drivers/staging/media/av7110/av7110.h
drivers/staging/media/av7110/av7110_av.h
drivers/staging/media/av7110/av7110_ca.h
drivers/staging/media/av7110/av7110_hw.h
drivers/staging/media/av7110/av7110_ipack.h

index 403dbbba5b5babeb5d08567093e7d4eda3733207..ec461fd187af47dbbb55b9037c508346e1dde41f 100644 (file)
@@ -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_ */
index f1c5c26c668b6df8eb4e2fd1aa4d9f53556387c5..eebaf59c7585a6d1f0abcd468775094807d491b0 100644 (file)
@@ -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_ */
index a6e3f2955730d6e56af7158bd6d777adbb8dede1..d3521944b97c6924571adc887b5b7617ec0f6b87 100644 (file)
@@ -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_ */
index c13b8c479eb75c3b7d928e31e7117cfc3a42d984..d4579f411c56d6c883e52c585a25c7ad8dc4d604 100644 (file)
@@ -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_ */
index 943ec899bb93e651a0ab90e4f04934cd077d2793..55296421d52fa14edf273c6bcbfd47fe77d39f48 100644 (file)
@@ -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