* Re: [PATCH v3 net 2/9] bridge: Fix the way to insert new local fdb entries in br_fdb_changeaddr
From: Stephen Hemminger @ 2014-02-07 16:31 UTC (permalink / raw)
To: Toshiaki Makita; +Cc: David S . Miller, Vlad Yasevich, netdev
In-Reply-To: <1391759306-24956-3-git-send-email-makita.toshiaki@lab.ntt.co.jp>
On Fri, 7 Feb 2014 16:48:19 +0900
Toshiaki Makita <makita.toshiaki@lab.ntt.co.jp> wrote:
> Since commit bc9a25d21ef8 ("bridge: Add vlan support for local fdb entries"),
> br_fdb_changeaddr() has inserted a new local fdb entry only if it can
> find old one. But if we have two ports where they have the same address
> or user has deleted a local entry, there will be no entry for one of the
> ports.
>
> Example of problematic case:
> ip link set eth0 address aa:bb:cc:dd:ee:ff
> ip link set eth1 address aa:bb:cc:dd:ee:ff
> brctl addif br0 eth0
> brctl addif br0 eth1 # eth1 will not have a local entry due to dup.
I think the second addif should fail, it doesn't seem valid to have
two interfaces on same bridge with same address. Most hardware switches
would disable the port in that case.
^ permalink raw reply
* Re: [PATCH v2.53] datapath: Add basic MPLS support to kernel
From: Ben Pfaff @ 2014-02-07 16:15 UTC (permalink / raw)
To: Jesse Gross, Simon Horman
Cc: dev-yBygre7rU0TnMu66kgdUjQ, netdev-u79uwXL29TY76Z2rM5mHXA, Ravi K
In-Reply-To: <1391590479-15567-1-git-send-email-horms-/R6kz+dDXgpPR4JQBCEnsQ@public.gmane.org>
On Wed, Feb 05, 2014 at 05:54:38PM +0900, Simon Horman wrote:
> * Ben has explained to me that there has been a change of direction
> at the ONF with regards to MPLS and VLAN tag ordering. As per
> his changelog for "Always insert MPLS labels after VLAN tags",
> the situation is now as follows:
>
> * OpenFlow 1.1 and 1.2 always inserted MPLS labels after VLAN tags.
> * OpenFlow 1.3 and 1.4 insert MPLS labels before VLAN tags.
> * OpenFlow 1.3.4 and 1.5, both in preparation, recognize that the change
> in 1.3 was an error and revert it.
>
> With this in mind only OF1.4 specifies a requirement for inserting MPLS
> labels before VLAN tags. This appears to be an abbertation at this
> point.
>
> Ben's suggestion as per his patch "Always insert MPLS labels after VLAN
> tags" is that Open vSwtich should only support inserting MPLS labels
> after VLAN tags. I agree with this. And to this end I have
> updated the MPLS code for the kernel datapath (this patch).
I spoke to Jesse briefly about MPLS versus VLANs a few days ago. He
expressed a concern about the larger problem of figuring out how all the
various forms of tags should interact: VLAN, MPLS, PBB, and others that
I can't think of at the moment. It would be more consistent from this
higher point of view if "push" and "pop" actions always acted in a
predictable place.
I agree with that point, but it still stands that I don't know of a
well-defined way for VLAN-inside-MPLS to function. So here is my
proposal for you and Jesse to consider:
- The datapath push_mpls action is well-defined when no VLAN is
present. Great.
- Declare the behavior of the datapath push_mpls action to be
undefined in the presence of a VLAN for now, since we don't
really know what should happen. For now, make the datapaths
reject any flow that does push_mpls in the presence of a VLAN.
Later, we can redefine that case as we please since userspace
should not depend on the previous behavior.
- Modify userspace to pop_vlan, push_mpls, push_vlan if
necessary to avoid the undefined behavior.
Jesse, is that reasonable?
^ permalink raw reply
* Re: nonagle flags for TSQ
From: Eric Dumazet @ 2014-02-07 15:58 UTC (permalink / raw)
To: John Ogness; +Cc: netdev
In-Reply-To: <1391787297.10160.50.camel@edumazet-glaptop2.roam.corp.google.com>
On Fri, 2014-02-07 at 07:34 -0800, Eric Dumazet wrote:
> On Fri, 2014-02-07 at 16:08 +0100, John Ogness wrote:
> > Hi,
> >
> > This email is referring to your Linux patch
> > 46d3ceabd8d98ed0ad10f20c595ca784e34786c5.
> >
> > https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=46d3ceabd8d98ed0ad10f20c595ca784e34786c5
> >
> > I have a question about the use of tcp_write_xmit() in
> > net/ipv4/tcp_output.c
> >
> > When tcp_write_xmit() is called, the nonagle flag of the tcp socket is
> > ignored and instead 0 is passed. This causes the Nagle-algorithm to be
> > used even if it should not be, which in some cases causes a large delay.
> >
> > Was there a reason that 0 was hard-coded?
> >
> > Although current mainline code has been refactored, 0 is still
> > hard-coded for TSQ cases.
>
> Hi John
>
> Do you have any data, like exact kernel version you use, tcpdump or
> things like that ?
>
> When the TCP writes are throttled, its only up to the point next packet
> is TX completed, and only if you have at least 128KB worth of bytes
> consumed in the QDISC/NIC layers for this socket.
>
> We had some issues at very high speeds, not related to Nagle at all.
>
> 98e09386c0ef tcp: tsq: restore minimal amount of queueing
> c9eeec26e32e tcp: TSQ can use a dynamic limit
> d6a4a1041176 tcp: GSO should be TSQ friendly
> d01cb20711e3 tcp: add LAST_ACK as a valid state for TSQ
>
> I am not aware of TSQ being a problem for Nagle.
>
> Also take a look at recent TCP autocork patches, as they are more
> related to Nagle
>
> a181ceb501b3 tcp: autocork should not hold first packet in write queue
> f54b311142a9 tcp: auto corking
>
> Thanks
I think I mentioned this once, but the "a181ceb501b3" fix
included this bit :
Also, as TX completion is lockless, it's safer to perform sk_wmem_alloc
test after setting TSQ_THROTTLED.
So its possible you hit the same race, its only a guess...
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c
index 03d26b85eab8..c99a63c6e91a 100644
--- a/net/ipv4/tcp_output.c
+++ b/net/ipv4/tcp_output.c
@@ -1904,7 +1904,12 @@ static bool tcp_write_xmit(struct sock *sk, unsigned int mss_now, int nonagle,
if (atomic_read(&sk->sk_wmem_alloc) > limit) {
set_bit(TSQ_THROTTLED, &tp->tsq_flags);
- break;
+ /* It is possible TX completion already happened
+ * before we set TSQ_THROTTLED, so we must
+ * test again the condition.
+ */
+ if (atomic_read(&sk->sk_wmem_alloc) > limit)
+ break;
}
limit = mss_now;
^ permalink raw reply related
* Re: nonagle flags for TSQ
From: Eric Dumazet @ 2014-02-07 15:34 UTC (permalink / raw)
To: John Ogness; +Cc: netdev
In-Reply-To: <87fvnv2c5k.fsf@linutronix.de>
On Fri, 2014-02-07 at 16:08 +0100, John Ogness wrote:
> Hi,
>
> This email is referring to your Linux patch
> 46d3ceabd8d98ed0ad10f20c595ca784e34786c5.
>
> https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=46d3ceabd8d98ed0ad10f20c595ca784e34786c5
>
> I have a question about the use of tcp_write_xmit() in
> net/ipv4/tcp_output.c
>
> When tcp_write_xmit() is called, the nonagle flag of the tcp socket is
> ignored and instead 0 is passed. This causes the Nagle-algorithm to be
> used even if it should not be, which in some cases causes a large delay.
>
> Was there a reason that 0 was hard-coded?
>
> Although current mainline code has been refactored, 0 is still
> hard-coded for TSQ cases.
Hi John
Do you have any data, like exact kernel version you use, tcpdump or
things like that ?
When the TCP writes are throttled, its only up to the point next packet
is TX completed, and only if you have at least 128KB worth of bytes
consumed in the QDISC/NIC layers for this socket.
We had some issues at very high speeds, not related to Nagle at all.
98e09386c0ef tcp: tsq: restore minimal amount of queueing
c9eeec26e32e tcp: TSQ can use a dynamic limit
d6a4a1041176 tcp: GSO should be TSQ friendly
d01cb20711e3 tcp: add LAST_ACK as a valid state for TSQ
I am not aware of TSQ being a problem for Nagle.
Also take a look at recent TCP autocork patches, as they are more
related to Nagle
a181ceb501b3 tcp: autocork should not hold first packet in write queue
f54b311142a9 tcp: auto corking
Thanks
^ permalink raw reply
* nonagle flags for TSQ
From: John Ogness @ 2014-02-07 15:08 UTC (permalink / raw)
To: netdev; +Cc: Eric Dumazet
Hi,
This email is referring to your Linux patch
46d3ceabd8d98ed0ad10f20c595ca784e34786c5.
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=46d3ceabd8d98ed0ad10f20c595ca784e34786c5
I have a question about the use of tcp_write_xmit() in
net/ipv4/tcp_output.c
When tcp_write_xmit() is called, the nonagle flag of the tcp socket is
ignored and instead 0 is passed. This causes the Nagle-algorithm to be
used even if it should not be, which in some cases causes a large delay.
Was there a reason that 0 was hard-coded?
Although current mainline code has been refactored, 0 is still
hard-coded for TSQ cases.
John Ogness
^ permalink raw reply
* RE: [PATCH] net: asix: fix bad header length bug
From: David Laight @ 2014-02-07 14:40 UTC (permalink / raw)
To: 'Emil Goode', Bjørn Mork
Cc: 'Igor Gnatenko', David S. Miller, Ming Lei, Mark Brown,
Jeff Kirsher, Glen Turner, linux-usb@vger.kernel.org,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
In-Reply-To: <20140207135320.GA4252@lianli>
From: Emil Goode
> On Fri, Feb 07, 2014 at 10:38:04AM +0100, Bjørn Mork wrote:
> > Emil Goode <emilgoode@gmail.com> writes:
> > > On Thu, Feb 06, 2014 at 03:28:13PM +0000, David Laight wrote:
> > >> From: Igor Gnatenko
> > >> > On Thu, 2014-02-06 at 13:56 +0100, Emil Goode wrote:
> > >> > > The AX88772B occasionally send rx packets that cross urb boundaries
> > >> > > and the remaining partial packet is sent with no header.
> > >> > > When the buffer with a partial packet is of less number of octets
> > >> > > than the value of hard_header_len the buffer is discarded by the
> > >> > > usbnet module. This is causing dropped packages and error messages
> > >> > > in dmesg.
> >
> > > I will do some more digging in the code, but the test of skb->len
> > > against hard_header_len is done already in the completion callback
> > > function passed to usb_fill_bulk_urb so it seems that buffers of less
> > > than hard_header_len number of octets will be dropped regardless.
> >
> > I am pretty sure you are right about this bug. And the exact same
> > solution is already used by the cx82310_eth minidriver, so I don't see
> > the problem. Your fix is fine IMHO. But you should apply it to all the
> > devices using asix_rx_fixup_common(), not just the ax88772 ones.
> >
> > You could maybe make this a usbnet flag instead and create a generic
> > solution in usbnet, but frankly I believe the number of flags and their
> > meaning have exceeded drivers authors capabilities a long time ago. At
> > least mine, which are quite limited ;-)
> >
> > An example of that problem is another bloody obvious bug I noticed while
> > looking at this driver: The 'struct driver_info ax88178_info' points to
> > asix_rx_fixup_common without setting the FLAG_MULTI_PACKET. This will
> > result in usbnet rx_process() calling usbnet_skb_return() on skbs which
> > are already consumed by the minidriver. Not a big problem, but will
> > give some odd results. But if you allow skbs shorter than ETH_HLEN to
> > slip through then it might go boom, so you should probably fix that as
> > well.
> >
> >
> > Bjørn
>
> Yes I believe the patch is necessary, but maybe it would be nice with
> a prettier solution rather than setting hard_header_len to 0 for all
> devices with this behaviour. Perhaps it would be better to let each
> driver that uses the usbnet module decide what skbs to discard?
>
> What David describes seems to be another bug, but I don't think it is
> related to this patch as I'm able to reproduce the bug without the patch
> beeing applied by setting the mtu to pretty much any value other than
> 1500 and using ping with a larger packet size than that mtu value.
Yes - plenty of bugs if you just look for them!
I did a quick scan through the sub-drivers and although the usbnet code
seems to treat the 'hard_header_len' as a constant to add to the mtu when
allocating rx urb (when the driver doesn't set rx_urb_len), some of the
sub-drivers seem to have three length, the rx header, tx header and hard_header,
and set them separately (I've not just rechecked) - which may not exactly
match what the usbnet code does is the lengths are different.
The ax88772b driver seems to support several different bits of silicon.
Only some put multiple ethernet frames in a single urb, and only for these
does the driver set the rx_urb_length to 2048.
For the other silicon it relies on usbnet setting the rx urb size - so
the hard_header_len better not be set to zero.
Someone with some time to spare needs to modify usbnet to support page
aligned rx buffers (probably 4k urb) and then build correctly formatted
skb from them.
At the moment the ax179_178a driver allocates 20kB urb which end up
with an 0x40 byte offset into the page (so are probably 24k) and
then cause alignment issues in the xhci driver which currently doesn't
correctly handle non-aligned 64k address boundaries when the cross the
ring end.
David
^ permalink raw reply
* Re: [PATCH] net: asix: fix bad header length bug
From: Emil Goode @ 2014-02-07 13:53 UTC (permalink / raw)
To: Bjørn Mork
Cc: David Laight, 'Igor Gnatenko', David S. Miller, Ming Lei,
Mark Brown, Jeff Kirsher, Glen Turner, linux-usb@vger.kernel.org,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
In-Reply-To: <87wqh7i7pf.fsf@nemi.mork.no>
On Fri, Feb 07, 2014 at 10:38:04AM +0100, Bjørn Mork wrote:
> Emil Goode <emilgoode@gmail.com> writes:
> > On Thu, Feb 06, 2014 at 03:28:13PM +0000, David Laight wrote:
> >> From: Igor Gnatenko
> >> > On Thu, 2014-02-06 at 13:56 +0100, Emil Goode wrote:
> >> > > The AX88772B occasionally send rx packets that cross urb boundaries
> >> > > and the remaining partial packet is sent with no header.
> >> > > When the buffer with a partial packet is of less number of octets
> >> > > than the value of hard_header_len the buffer is discarded by the
> >> > > usbnet module. This is causing dropped packages and error messages
> >> > > in dmesg.
>
> > I will do some more digging in the code, but the test of skb->len
> > against hard_header_len is done already in the completion callback
> > function passed to usb_fill_bulk_urb so it seems that buffers of less
> > than hard_header_len number of octets will be dropped regardless.
>
> I am pretty sure you are right about this bug. And the exact same
> solution is already used by the cx82310_eth minidriver, so I don't see
> the problem. Your fix is fine IMHO. But you should apply it to all the
> devices using asix_rx_fixup_common(), not just the ax88772 ones.
>
> You could maybe make this a usbnet flag instead and create a generic
> solution in usbnet, but frankly I believe the number of flags and their
> meaning have exceeded drivers authors capabilities a long time ago. At
> least mine, which are quite limited ;-)
>
> An example of that problem is another bloody obvious bug I noticed while
> looking at this driver: The 'struct driver_info ax88178_info' points to
> asix_rx_fixup_common without setting the FLAG_MULTI_PACKET. This will
> result in usbnet rx_process() calling usbnet_skb_return() on skbs which
> are already consumed by the minidriver. Not a big problem, but will
> give some odd results. But if you allow skbs shorter than ETH_HLEN to
> slip through then it might go boom, so you should probably fix that as
> well.
>
>
> Bjørn
Yes I believe the patch is necessary, but maybe it would be nice with
a prettier solution rather than setting hard_header_len to 0 for all
devices with this behaviour. Perhaps it would be better to let each
driver that uses the usbnet module decide what skbs to discard?
What David describes seems to be another bug, but I don't think it is
related to this patch as I'm able to reproduce the bug without the patch
beeing applied by setting the mtu to pretty much any value other than
1500 and using ping with a larger packet size than that mtu value.
Best regards,
Emil Goode
^ permalink raw reply
* RE: [PATCH 19/26] drivers: isdn: Move prototype declaration to header file platform.h from diva_didd.c
From: David Laight @ 2014-02-07 13:33 UTC (permalink / raw)
To: 'Rashika Kheria', linux-kernel@vger.kernel.org
Cc: Armin Schindler, Karsten Keil, netdev@vger.kernel.org,
josh@joshtriplett.org
In-Reply-To: <93d7188538418423685ecefaf3d2bb311b37be6e.1390408518.git.rashika.kheria@gmail.com>
From: Rashika Kheria
> Move prototype declarations of function to header file
> hardware/eicon/platform.h because they are used by more than one file.
>
> This eliminates the following warnings in hardware/eicon/diddfunc.c:
> drivers/isdn/hardware/eicon/diddfunc.c:95:12: warning: no previous prototype for diddfunc_init [-
> Wmissing-prototypes]
> drivers/isdn/hardware/eicon/diddfunc.c:110:13: warning: no previous prototype for diddfunc_finit [-
> Wmissing-prototypes]
...
> diff --git a/drivers/isdn/hardware/eicon/diva_didd.c b/drivers/isdn/hardware/eicon/diva_didd.c
> index fab6ccf..56d32a7 100644
> --- a/drivers/isdn/hardware/eicon/diva_didd.c
> +++ b/drivers/isdn/hardware/eicon/diva_didd.c
> @@ -39,9 +39,6 @@ MODULE_LICENSE("GPL");
> #define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
> #define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
>
> -extern int diddfunc_init(void);
> -extern void diddfunc_finit(void);
> -
> extern void DIVA_DIDD_Read(void *, int);
You should move that one as well.
There really shouldn't be 'extern' definitions for any function in
any C files since you want the compiler to check they are correct
when the function itself is compiled.
David
^ permalink raw reply
* [PATCH 26/26] drivers: isdn: Move prototype declaration to header file platform.h from divasmain.c
From: Rashika Kheria @ 2014-02-07 12:49 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declaration of functions to header file
hardware/eicon/platform.h because they are used by more than one file.
This elliminates the following warnings in hardware/eicon/divasproc.c:
drivers/isdn/hardware/eicon/divasproc.c:125:5: warning: no previous prototype for ‘create_divas_proc’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/divasproc.c:135:6: warning: no previous prototype for ‘remove_divas_proc’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/divasmain.c | 3 ---
drivers/isdn/hardware/eicon/platform.h | 2 ++
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/divasmain.c b/drivers/isdn/hardware/eicon/divasmain.c
index 6b15670..3b1e5bc 100644
--- a/drivers/isdn/hardware/eicon/divasmain.c
+++ b/drivers/isdn/hardware/eicon/divasmain.c
@@ -55,9 +55,6 @@ static char *DRIVERLNAME = "divas";
static char *DEVNAME = "Divas";
char *DRIVERRELEASE_DIVAS = "2.0";
-extern int create_divas_proc(void);
-extern void remove_divas_proc(void);
-
typedef struct _diva_os_thread_dpc {
struct tasklet_struct divas_task;
diva_os_soft_isr_t *psoft_isr;
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index 6bec7db..800b8bd 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -161,6 +161,8 @@ void diva_xdi_didd_remove_adapter(int card);
void diva_get_vserial_number(PISDN_ADAPTER IoAdapter, char *buf);
int divasfunc_init(int dbgmask);
void divasfunc_exit(void);
+int create_divas_proc(void);
+void remove_divas_proc(void);
/*
** memory allocation
--
1.7.9.5
^ permalink raw reply related
* [PATCH 25/26] drivers: isdn: Move prototype declaration to header file dadapter.h
From: Rashika Kheria @ 2014-02-07 12:48 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declaration of functions to header file
hardware/eicon/dadapter.h because they are used by more than one file.
This eliminates the following warning in hardware/eicon/dadapter.c:
drivers/isdn/hardware/eicon/dadapter.c:361:22: warning: no previous prototype for ‘DIVA_DIDD_Read’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/capifunc.c | 3 +--
drivers/isdn/hardware/eicon/dadapter.h | 1 +
drivers/isdn/hardware/eicon/diddfunc.c | 1 -
drivers/isdn/hardware/eicon/diva_didd.c | 2 --
drivers/isdn/hardware/eicon/divasfunc.c | 3 +--
drivers/isdn/hardware/eicon/idifunc.c | 3 +--
drivers/isdn/hardware/eicon/mntfunc.c | 3 +--
7 files changed, 5 insertions(+), 11 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/capifunc.c b/drivers/isdn/hardware/eicon/capifunc.c
index 639d70f..3bcb602 100644
--- a/drivers/isdn/hardware/eicon/capifunc.c
+++ b/drivers/isdn/hardware/eicon/capifunc.c
@@ -18,6 +18,7 @@
#include "divacapi.h"
#include "divasync.h"
#include "capifunc.h"
+#include "dadapter.h"
#define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
@@ -55,8 +56,6 @@ static char *diva_procinfo(struct capi_ctr *);
static u16 diva_send_message(struct capi_ctr *,
diva_os_message_buffer_s *);
-extern void DIVA_DIDD_Read(DESCRIPTOR *, int);
-
/*
* debug
*/
diff --git a/drivers/isdn/hardware/eicon/dadapter.h b/drivers/isdn/hardware/eicon/dadapter.h
index 5540f46..f6cdebf 100644
--- a/drivers/isdn/hardware/eicon/dadapter.h
+++ b/drivers/isdn/hardware/eicon/dadapter.h
@@ -28,6 +28,7 @@
void diva_didd_load_time_init(void);
void diva_didd_load_time_finit(void);
+void IDI_CALL_LINK_T DIVA_DIDD_Read(void IDI_CALL_ENTITY_T *buffer, int length);
#define NEW_MAX_DESCRIPTORS 64
diff --git a/drivers/isdn/hardware/eicon/diddfunc.c b/drivers/isdn/hardware/eicon/diddfunc.c
index b0b23ed..a8a229f 100644
--- a/drivers/isdn/hardware/eicon/diddfunc.c
+++ b/drivers/isdn/hardware/eicon/diddfunc.c
@@ -20,7 +20,6 @@
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
-extern void DIVA_DIDD_Read(void *, int);
extern char *DRIVERRELEASE_DIDD;
static dword notify_handle;
static DESCRIPTOR _DAdapter;
diff --git a/drivers/isdn/hardware/eicon/diva_didd.c b/drivers/isdn/hardware/eicon/diva_didd.c
index 56d32a7..b8e525f 100644
--- a/drivers/isdn/hardware/eicon/diva_didd.c
+++ b/drivers/isdn/hardware/eicon/diva_didd.c
@@ -39,8 +39,6 @@ MODULE_LICENSE("GPL");
#define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
-extern void DIVA_DIDD_Read(void *, int);
-
static struct proc_dir_entry *proc_didd;
struct proc_dir_entry *proc_net_eicon = NULL;
diff --git a/drivers/isdn/hardware/eicon/divasfunc.c b/drivers/isdn/hardware/eicon/divasfunc.c
index 4be5f88..a5d44d0 100644
--- a/drivers/isdn/hardware/eicon/divasfunc.c
+++ b/drivers/isdn/hardware/eicon/divasfunc.c
@@ -17,14 +17,13 @@
#include "divasync.h"
#include "diva.h"
#include "xdi_vers.h"
+#include "dadapter.h"
#define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
static int debugmask;
-extern void DIVA_DIDD_Read(void *, int);
-
extern PISDN_ADAPTER IoAdapters[MAX_ADAPTER];
extern char *DRIVERRELEASE_DIVAS;
diff --git a/drivers/isdn/hardware/eicon/idifunc.c b/drivers/isdn/hardware/eicon/idifunc.c
index bacab74..dc79095 100644
--- a/drivers/isdn/hardware/eicon/idifunc.c
+++ b/drivers/isdn/hardware/eicon/idifunc.c
@@ -15,14 +15,13 @@
#include "divasync.h"
#include "um_xdi.h"
#include "um_idi.h"
+#include "dadapter.h"
#define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
extern char *DRIVERRELEASE_IDI;
-extern void DIVA_DIDD_Read(void *, int);
-
static dword notify_handle;
static DESCRIPTOR DAdapter;
static DESCRIPTOR MAdapter;
diff --git a/drivers/isdn/hardware/eicon/mntfunc.c b/drivers/isdn/hardware/eicon/mntfunc.c
index e304a1d..be47431 100644
--- a/drivers/isdn/hardware/eicon/mntfunc.c
+++ b/drivers/isdn/hardware/eicon/mntfunc.c
@@ -15,14 +15,13 @@
#include "di_defs.h"
#include "divasync.h"
#include "debug_if.h"
+#include "dadapter.h"
extern char *DRIVERRELEASE_MNT;
#define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
-extern void DIVA_DIDD_Read(void *, int);
-
static dword notify_handle;
static DESCRIPTOR DAdapter;
static DESCRIPTOR MAdapter;
--
1.7.9.5
^ permalink raw reply related
* [PATCH 24/26] drivers: isdn: Move prototype declaration to header file hisax.h from config.c
From: Rashika Kheria @ 2014-02-07 12:47 UTC (permalink / raw)
To: linux-kernel
Cc: Karsten Keil, Andrew Morton, David S. Miller, Kees Cook, netdev,
josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declaration of functions to header file hisax/hisax.h
because they are used by more than one file.
This eliminates the following warnings:
drivers/isdn/hisax/teles3.c:273:5: warning: no previous prototype for ‘setup_teles3’ [-Wmissing-prototypes]
drivers/isdn/hisax/telespci.c:288:5: warning: no previous prototype for ‘setup_telespci’ [-Wmissing-prototypes]
drivers/isdn/hisax/s0box.c:213:5: warning: no previous prototype for ‘setup_s0box’ [-Wmissing-prototypes]
drivers/isdn/hisax/avm_a1p.c:216:5: warning: no previous prototype for ‘setup_avm_a1_pcmcia’ [-Wmissing-prototypes]
drivers/isdn/hisax/avm_pci.c:870:5: warning: no previous prototype for ‘setup_avm_pcipnp’ [-Wmissing-prototypes]
drivers/isdn/hisax/elsa.c:1209:5: warning: no previous prototype for ‘setup_elsa’ [-Wmissing-prototypes]
drivers/isdn/hisax/diva.c:1241:5: warning: no previous prototype for ‘setup_diva’ [-Wmissing-prototypes]
drivers/isdn/hisax/sedlbauer.c:674:5: warning: no previous prototype for ‘setup_sedlbauer’ [-Wmissing-prototypes]
drivers/isdn/hisax/nj_s.c:258:5: warning: no previous prototype for ‘setup_netjet_s’ [-Wmissing-prototypes]
drivers/isdn/hisax/nj_u.c:221:5: warning: no previous prototype for ‘setup_netjet_u’ [-Wmissing-prototypes]
drivers/isdn/hisax/hfc_pci.c:1638:1: warning: no previous prototype for ‘setup_hfcpci’ [-Wmissing-prototypes]
drivers/isdn/hisax/hfc_sx.c:1395:5: warning: no previous prototype for ‘setup_hfcsx’ [-Wmissing-prototypes]
drivers/isdn/hisax/niccy.c:229:5: warning: no previous prototype for ‘setup_niccy’ [-Wmissing-prototypes]
drivers/isdn/hisax/bkm_a4t.c:325:5: warning: no previous prototype for ‘setup_bkm_a4t’ [-Wmissing-prototypes]
drivers/isdn/hisax/bkm_a8.c:276:5: warning: no previous prototype for ‘setup_sct_quadro’ [-Wmissing-prototypes]
drivers/isdn/hisax/gazel.c:623:5: warning: no previous prototype for ‘setup_gazel’ [-Wmissing-prototypes]
drivers/isdn/hisax/w6692.c:996:5: warning: no previous prototype for ‘setup_w6692’ [-Wmissing-prototypes]
drivers/isdn/hisax/enternow_pci.c:387:5: warning: no previous prototype for ‘setup_enternow_pci’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hisax/config.c | 72 -------------------------------------------
drivers/isdn/hisax/hisax.h | 71 ++++++++++++++++++++++++++++++++++++++++++
2 files changed, 71 insertions(+), 72 deletions(-)
diff --git a/drivers/isdn/hisax/config.c b/drivers/isdn/hisax/config.c
index b33f53b..196cbb8 100644
--- a/drivers/isdn/hisax/config.c
+++ b/drivers/isdn/hisax/config.c
@@ -460,42 +460,14 @@ __setup("hisax=", HiSax_setup);
extern int setup_teles0(struct IsdnCard *card);
#endif
-#if CARD_TELES3
-extern int setup_teles3(struct IsdnCard *card);
-#endif
-
-#if CARD_S0BOX
-extern int setup_s0box(struct IsdnCard *card);
-#endif
-
-#if CARD_TELESPCI
-extern int setup_telespci(struct IsdnCard *card);
-#endif
-
#if CARD_AVM_A1
extern int setup_avm_a1(struct IsdnCard *card);
#endif
-#if CARD_AVM_A1_PCMCIA
-extern int setup_avm_a1_pcmcia(struct IsdnCard *card);
-#endif
-
-#if CARD_FRITZPCI
-extern int setup_avm_pcipnp(struct IsdnCard *card);
-#endif
-
-#if CARD_ELSA
-extern int setup_elsa(struct IsdnCard *card);
-#endif
-
#if CARD_IX1MICROR2
extern int setup_ix1micro(struct IsdnCard *card);
#endif
-#if CARD_DIEHLDIVA
-extern int setup_diva(struct IsdnCard *card);
-#endif
-
#if CARD_ASUSCOM
extern int setup_asuscom(struct IsdnCard *card);
#endif
@@ -504,10 +476,6 @@ extern int setup_asuscom(struct IsdnCard *card);
extern int setup_TeleInt(struct IsdnCard *card);
#endif
-#if CARD_SEDLBAUER
-extern int setup_sedlbauer(struct IsdnCard *card);
-#endif
-
#if CARD_SPORTSTER
extern int setup_sportster(struct IsdnCard *card);
#endif
@@ -516,26 +484,10 @@ extern int setup_sportster(struct IsdnCard *card);
extern int setup_mic(struct IsdnCard *card);
#endif
-#if CARD_NETJET_S
-extern int setup_netjet_s(struct IsdnCard *card);
-#endif
-
#if CARD_HFCS
extern int setup_hfcs(struct IsdnCard *card);
#endif
-#if CARD_HFC_PCI
-extern int setup_hfcpci(struct IsdnCard *card);
-#endif
-
-#if CARD_HFC_SX
-extern int setup_hfcsx(struct IsdnCard *card);
-#endif
-
-#if CARD_NICCY
-extern int setup_niccy(struct IsdnCard *card);
-#endif
-
#if CARD_ISURF
extern int setup_isurf(struct IsdnCard *card);
#endif
@@ -544,30 +496,6 @@ extern int setup_isurf(struct IsdnCard *card);
extern int setup_saphir(struct IsdnCard *card);
#endif
-#if CARD_BKM_A4T
-extern int setup_bkm_a4t(struct IsdnCard *card);
-#endif
-
-#if CARD_SCT_QUADRO
-extern int setup_sct_quadro(struct IsdnCard *card);
-#endif
-
-#if CARD_GAZEL
-extern int setup_gazel(struct IsdnCard *card);
-#endif
-
-#if CARD_W6692
-extern int setup_w6692(struct IsdnCard *card);
-#endif
-
-#if CARD_NETJET_U
-extern int setup_netjet_u(struct IsdnCard *card);
-#endif
-
-#if CARD_FN_ENTERNOW_PCI
-extern int setup_enternow_pci(struct IsdnCard *card);
-#endif
-
/*
* Find card with given driverId
*/
diff --git a/drivers/isdn/hisax/hisax.h b/drivers/isdn/hisax/hisax.h
index 6ead6314..90d68d1 100644
--- a/drivers/isdn/hisax/hisax.h
+++ b/drivers/isdn/hisax/hisax.h
@@ -1327,6 +1327,77 @@ void release_tei(struct IsdnCardState *cs);
char *HiSax_getrev(const char *revision);
int TeiNew(void);
void TeiFree(void);
+#if CARD_TELES3
+int setup_teles3(struct IsdnCard *card);
+#endif
+
+#if CARD_TELESPCI
+extern int setup_telespci(struct IsdnCard *card);
+#endif
+
+#if CARD_S0BOX
+extern int setup_s0box(struct IsdnCard *card);
+#endif
+
+#if CARD_AVM_A1_PCMCIA
+extern int setup_avm_a1_pcmcia(struct IsdnCard *card);
+#endif
+
+#if CARD_FRITZPCI
+extern int setup_avm_pcipnp(struct IsdnCard *card);
+#endif
+
+#if CARD_ELSA
+extern int setup_elsa(struct IsdnCard *card);
+#endif
+
+#if CARD_DIEHLDIVA
+extern int setup_diva(struct IsdnCard *card);
+#endif
+
+#if CARD_SEDLBAUER
+extern int setup_sedlbauer(struct IsdnCard *card);
+#endif
+
+#if CARD_NETJET_S
+extern int setup_netjet_s(struct IsdnCard *card);
+#endif
+
+#if CARD_HFC_PCI
+extern int setup_hfcpci(struct IsdnCard *card);
+#endif
+
+#if CARD_HFC_SX
+extern int setup_hfcsx(struct IsdnCard *card);
+#endif
+
+#if CARD_NICCY
+extern int setup_niccy(struct IsdnCard *card);
+#endif
+
+#if CARD_BKM_A4T
+extern int setup_bkm_a4t(struct IsdnCard *card);
+#endif
+
+#if CARD_SCT_QUADRO
+extern int setup_sct_quadro(struct IsdnCard *card);
+#endif
+
+#if CARD_GAZEL
+extern int setup_gazel(struct IsdnCard *card);
+#endif
+
+#if CARD_W6692
+extern int setup_w6692(struct IsdnCard *card);
+#endif
+
+#if CARD_NETJET_U
+extern int setup_netjet_u(struct IsdnCard *card);
+#endif
+
+#if CARD_FN_ENTERNOW_PCI
+extern int setup_enternow_pci(struct IsdnCard *card);
+#endif
#ifdef CONFIG_PCI
--
1.7.9.5
^ permalink raw reply related
* [PATCH 23/26] drivers: isdn: Move prototype declaration to header file platform.h from divamnt.c
From: Rashika Kheria @ 2014-02-07 12:46 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declaration of functions to header file
hardware/eicon/platform.h because they are used by more than one file.
This eliminates the following warnings in hardware/eicon/mntfunc.c:
drivers/isdn/hardware/eicon/mntfunc.c:136:5: warning: no previous prototype for ‘maint_read_write’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/mntfunc.c:303:12: warning: no previous prototype for ‘mntfunc_init’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/mntfunc.c:351:13: warning: no previous prototype for ‘mntfunc_finit’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/divamnt.c | 4 ----
drivers/isdn/hardware/eicon/platform.h | 4 ++++
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/divamnt.c b/drivers/isdn/hardware/eicon/divamnt.c
index 48db08d..02a1d0d 100644
--- a/drivers/isdn/hardware/eicon/divamnt.c
+++ b/drivers/isdn/hardware/eicon/divamnt.c
@@ -47,10 +47,6 @@ static wait_queue_head_t msgwaitq;
static unsigned long opened;
static struct timeval start_time;
-extern int mntfunc_init(int *, void **, unsigned long);
-extern void mntfunc_finit(void);
-extern int maint_read_write(void __user *buf, int count);
-
/*
* helper functions
*/
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index f26f6cb..6bec7db 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -195,6 +195,10 @@ int qBri_FPGA_download(PISDN_ADAPTER IoAdapter);
void prepare_pri_functions(PISDN_ADAPTER IoAdapter);
void prepare_pri2_functions(PISDN_ADAPTER IoAdapter);
+int mntfunc_init(int *, void **, unsigned long);
+void mntfunc_finit(void);
+int maint_read_write(void __user *buf, int count);
+
/*
** use skbuffs for message buffer
*/
--
1.7.9.5
^ permalink raw reply related
* [PATCH 22/26] drivers: isdn: Move prototype declaration to header file platform.h from os_pri.c
From: Rashika Kheria @ 2014-02-07 12:45 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declarations of functions to header file because they are
used by more than file.
This eliminates the following warnings in hardware/eicon/s_pri.c:
drivers/isdn/hardware/eicon/s_pri.c:192:6: warning: no previous prototype for ‘prepare_pri_functions’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/s_pri.c:200:6: warning: no previous prototype for ‘prepare_pri2_functions’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/os_pri.c | 6 ------
drivers/isdn/hardware/eicon/platform.h | 3 +++
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/os_pri.c b/drivers/isdn/hardware/eicon/os_pri.c
index acc1de6..129007c 100644
--- a/drivers/isdn/hardware/eicon/os_pri.c
+++ b/drivers/isdn/hardware/eicon/os_pri.c
@@ -30,12 +30,6 @@
#define DIVA_PRI_NO_PCI_BIOS_WORKAROUND 1
-/*
-** IMPORTS
-*/
-extern void prepare_pri_functions(PISDN_ADAPTER IoAdapter);
-extern void prepare_pri2_functions(PISDN_ADAPTER IoAdapter);
-
static int diva_pri_cleanup_adapter(diva_os_xdi_adapter_t *a);
static int diva_pri_cmd_card_proc(struct _diva_os_xdi_adapter *a,
diva_xdi_um_cfg_cmd_t *cmd, int length);
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index af3d0a6..f26f6cb 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -192,6 +192,9 @@ void prepare_qBri_functions(PISDN_ADAPTER IoAdapter);
void prepare_qBri2_functions(PISDN_ADAPTER IoAdapter);
int qBri_FPGA_download(PISDN_ADAPTER IoAdapter);
+void prepare_pri_functions(PISDN_ADAPTER IoAdapter);
+void prepare_pri2_functions(PISDN_ADAPTER IoAdapter);
+
/*
** use skbuffs for message buffer
*/
--
1.7.9.5
^ permalink raw reply related
* [PATCH 21/26] drivers: isdn: Move prototype declaration to header file platform.h from os_4bri.c
From: Rashika Kheria @ 2014-02-07 12:44 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declaration of functions to header file
hardware/eicon/platform.h because they are used by more than one file.
This eliminates the following warnings in hardware/eicon/s_4bri.c:
drivers/isdn/hardware/eicon/s_4bri.c:128:6: warning: no previous prototype for ‘start_qBri_hardware’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/s_4bri.c:275:5: warning: no previous prototype for ‘qBri_FPGA_download’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/s_4bri.c:487:6: warning: no previous prototype for ‘prepare_qBri_functions’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/s_4bri.c:496:6: warning: no previous prototype for ‘prepare_qBri2_functions’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/os_4bri.c | 9 ---------
drivers/isdn/hardware/eicon/platform.h | 5 +++++
2 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/os_4bri.c b/drivers/isdn/hardware/eicon/os_4bri.c
index 54f7033..287ceee 100644
--- a/drivers/isdn/hardware/eicon/os_4bri.c
+++ b/drivers/isdn/hardware/eicon/os_4bri.c
@@ -23,15 +23,6 @@ static void *diva_xdiLoadFileFile = NULL;
static dword diva_xdiLoadFileLength = 0;
/*
-** IMPORTS
-*/
-extern void prepare_qBri_functions(PISDN_ADAPTER IoAdapter);
-extern void prepare_qBri2_functions(PISDN_ADAPTER IoAdapter);
-
-extern int qBri_FPGA_download(PISDN_ADAPTER IoAdapter);
-extern void start_qBri_hardware(PISDN_ADAPTER IoAdapter);
-
-/*
** LOCALS
*/
static unsigned long _4bri_bar_length[4] = {
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index a507cea..af3d0a6 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -187,6 +187,11 @@ void diddfunc_finit(void);
void prepare_maestra_functions(PISDN_ADAPTER IoAdapter);
+void start_qBri_hardware(PISDN_ADAPTER IoAdapter);
+void prepare_qBri_functions(PISDN_ADAPTER IoAdapter);
+void prepare_qBri2_functions(PISDN_ADAPTER IoAdapter);
+int qBri_FPGA_download(PISDN_ADAPTER IoAdapter);
+
/*
** use skbuffs for message buffer
*/
--
1.7.9.5
^ permalink raw reply related
* [PATCH 20/26] drivers: isdn: Move prototype declaration to header file platform.h from os_bri.c
From: Rashika Kheria @ 2014-02-07 12:43 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declaration of function to header file because they are
used by more than one file.
This eliminates the following warnings in hardware/eicon/s_bri.c:
drivers/isdn/hardware/eicon/s_bri.c:163:6: warning: no previous prototype for ‘prepare_maestra_functions’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/os_bri.c | 5 -----
drivers/isdn/hardware/eicon/platform.h | 2 ++
2 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/os_bri.c b/drivers/isdn/hardware/eicon/os_bri.c
index c7a45e6..b61e335 100644
--- a/drivers/isdn/hardware/eicon/os_bri.c
+++ b/drivers/isdn/hardware/eicon/os_bri.c
@@ -20,11 +20,6 @@
#include "diva.h"
/*
-** IMPORTS
-*/
-extern void prepare_maestra_functions(PISDN_ADAPTER IoAdapter);
-
-/*
** LOCALS
*/
static int bri_bar_length[3] = {
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index d648ab7..a507cea 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -185,6 +185,8 @@ void idifunc_finit(void);
int diddfunc_init(void);
void diddfunc_finit(void);
+void prepare_maestra_functions(PISDN_ADAPTER IoAdapter);
+
/*
** use skbuffs for message buffer
*/
--
1.7.9.5
^ permalink raw reply related
* [PATCH 19/26] drivers: isdn: Move prototype declaration to header file platform.h from diva_didd.c
From: Rashika Kheria @ 2014-02-07 12:42 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declarations of function to header file
hardware/eicon/platform.h because they are used by more than one file.
This eliminates the following warnings in hardware/eicon/diddfunc.c:
drivers/isdn/hardware/eicon/diddfunc.c:95:12: warning: no previous prototype for ‘diddfunc_init’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/diddfunc.c:110:13: warning: no previous prototype for ‘diddfunc_finit’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/diva_didd.c | 3 ---
drivers/isdn/hardware/eicon/platform.h | 3 +++
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/diva_didd.c b/drivers/isdn/hardware/eicon/diva_didd.c
index fab6ccf..56d32a7 100644
--- a/drivers/isdn/hardware/eicon/diva_didd.c
+++ b/drivers/isdn/hardware/eicon/diva_didd.c
@@ -39,9 +39,6 @@ MODULE_LICENSE("GPL");
#define DBG_MINIMUM (DL_LOG + DL_FTL + DL_ERR)
#define DBG_DEFAULT (DBG_MINIMUM + DL_XLOG + DL_REG)
-extern int diddfunc_init(void);
-extern void diddfunc_finit(void);
-
extern void DIVA_DIDD_Read(void *, int);
static struct proc_dir_entry *proc_didd;
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index 33d6be1..d648ab7 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -182,6 +182,9 @@ static __inline__ void diva_os_free(unsigned long flags, void *ptr)
int idifunc_init(void);
void idifunc_finit(void);
+int diddfunc_init(void);
+void diddfunc_finit(void);
+
/*
** use skbuffs for message buffer
*/
--
1.7.9.5
^ permalink raw reply related
* [PATCH 18/26] drivers: isdn: Mark functions as static in layer2.c
From: Rashika Kheria @ 2014-02-07 12:41 UTC (permalink / raw)
To: linux-kernel; +Cc: Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Mark functions as static in mISDN/layer2.c because they are not used
outside this file.
This eliminates following warnings in mISDN/layer2.c:
drivers/isdn/mISDN/layer2.c:120:1: warning: no previous prototype for ‘l2headersize’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:127:1: warning: no previous prototype for ‘l2addrsize’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:379:1: warning: no previous prototype for ‘cansend’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:391:1: warning: no previous prototype for ‘clear_exception’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:439:1: warning: no previous prototype for ‘IsUI’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:445:1: warning: no previous prototype for ‘IsUA’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:451:1: warning: no previous prototype for ‘IsDM’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:457:1: warning: no previous prototype for ‘IsDISC’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:463:1: warning: no previous prototype for ‘IsRR’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:472:1: warning: no previous prototype for ‘IsSFrame’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:482:1: warning: no previous prototype for ‘IsSABME’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:490:1: warning: no previous prototype for ‘IsREJ’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:497:1: warning: no previous prototype for ‘IsFRMR’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:503:1: warning: no previous prototype for ‘IsRNR’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:649:1: warning: no previous prototype for ‘get_PollFlag’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:655:1: warning: no previous prototype for ‘get_PollFlagFree’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:665:1: warning: no previous prototype for ‘start_t200’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:672:1: warning: no previous prototype for 'restart_t200’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:679:1: warning: no previous prototype for ‘stop_t200’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:686:1: warning: no previous prototype for ‘st5_dl_release_l2l3’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:698:1: warning: no previous prototype for ‘lapb_dl_release_l2l3’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:1133:1: warning: no previous prototype for ‘enquiry_response’ [-Wmissing-prototypes]
drivers/isdn/mISDN/layer2.c:1143:1: warning: no previous prototype for ‘transmit_enquiry’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/mISDN/layer2.c | 53 ++++++++++++++++++-------------------------
1 file changed, 22 insertions(+), 31 deletions(-)
diff --git a/drivers/isdn/mISDN/layer2.c b/drivers/isdn/mISDN/layer2.c
index 949cabb..b59e5ed 100644
--- a/drivers/isdn/mISDN/layer2.c
+++ b/drivers/isdn/mISDN/layer2.c
@@ -116,14 +116,14 @@ l2m_debug(struct FsmInst *fi, char *fmt, ...)
va_end(va);
}
-inline u_int
+static inline u_int
l2headersize(struct layer2 *l2, int ui)
{
return ((test_bit(FLG_MOD128, &l2->flag) && (!ui)) ? 2 : 1) +
(test_bit(FLG_LAPD, &l2->flag) ? 2 : 1);
}
-inline u_int
+static inline u_int
l2addrsize(struct layer2 *l2)
{
return test_bit(FLG_LAPD, &l2->flag) ? 2 : 1;
@@ -375,7 +375,7 @@ ReleaseWin(struct layer2 *l2)
"isdnl2 freed %d skbuffs in release\n", cnt);
}
-inline unsigned int
+static inline unsigned int
cansend(struct layer2 *l2)
{
unsigned int p1;
@@ -387,7 +387,7 @@ cansend(struct layer2 *l2)
return (p1 < l2->window) && !test_bit(FLG_PEER_BUSY, &l2->flag);
}
-inline void
+static inline void
clear_exception(struct layer2 *l2)
{
test_and_clear_bit(FLG_ACK_PEND, &l2->flag);
@@ -435,40 +435,31 @@ enqueue_ui(struct layer2 *l2, struct sk_buff *skb)
dev_kfree_skb(skb);
}
-inline int
+static inline int
IsUI(u_char *data)
{
return (data[0] & 0xef) == UI;
}
-inline int
+static inline int
IsUA(u_char *data)
{
return (data[0] & 0xef) == UA;
}
-inline int
+static inline int
IsDM(u_char *data)
{
return (data[0] & 0xef) == DM;
}
-inline int
+static inline int
IsDISC(u_char *data)
{
return (data[0] & 0xef) == DISC;
}
-inline int
-IsRR(u_char *data, struct layer2 *l2)
-{
- if (test_bit(FLG_MOD128, &l2->flag))
- return data[0] == RR;
- else
- return (data[0] & 0xf) == 1;
-}
-
-inline int
+static inline int
IsSFrame(u_char *data, struct layer2 *l2)
{
register u_char d = *data;
@@ -478,7 +469,7 @@ IsSFrame(u_char *data, struct layer2 *l2)
return ((d & 0xf3) == 1) && ((d & 0x0c) != 0x0c);
}
-inline int
+static inline int
IsSABME(u_char *data, struct layer2 *l2)
{
u_char d = data[0] & ~0x10;
@@ -486,20 +477,20 @@ IsSABME(u_char *data, struct layer2 *l2)
return test_bit(FLG_MOD128, &l2->flag) ? d == SABME : d == SABM;
}
-inline int
+static inline int
IsREJ(u_char *data, struct layer2 *l2)
{
return test_bit(FLG_MOD128, &l2->flag) ?
data[0] == REJ : (data[0] & 0xf) == REJ;
}
-inline int
+static inline int
IsFRMR(u_char *data)
{
return (data[0] & 0xef) == FRMR;
}
-inline int
+static inline int
IsRNR(u_char *data, struct layer2 *l2)
{
return test_bit(FLG_MOD128, &l2->flag) ?
@@ -645,13 +636,13 @@ send_uframe(struct layer2 *l2, struct sk_buff *skb, u_char cmd, u_char cr)
}
-inline u_char
+static inline u_char
get_PollFlag(struct layer2 *l2, struct sk_buff *skb)
{
return skb->data[l2addrsize(l2)] & 0x10;
}
-inline u_char
+static inline u_char
get_PollFlagFree(struct layer2 *l2, struct sk_buff *skb)
{
u_char PF;
@@ -661,28 +652,28 @@ get_PollFlagFree(struct layer2 *l2, struct sk_buff *skb)
return PF;
}
-inline void
+static inline void
start_t200(struct layer2 *l2, int i)
{
mISDN_FsmAddTimer(&l2->t200, l2->T200, EV_L2_T200, NULL, i);
test_and_set_bit(FLG_T200_RUN, &l2->flag);
}
-inline void
+static inline void
restart_t200(struct layer2 *l2, int i)
{
mISDN_FsmRestartTimer(&l2->t200, l2->T200, EV_L2_T200, NULL, i);
test_and_set_bit(FLG_T200_RUN, &l2->flag);
}
-inline void
+static inline void
stop_t200(struct layer2 *l2, int i)
{
if (test_and_clear_bit(FLG_T200_RUN, &l2->flag))
mISDN_FsmDelTimer(&l2->t200, i);
}
-inline void
+static inline void
st5_dl_release_l2l3(struct layer2 *l2)
{
int pr;
@@ -694,7 +685,7 @@ st5_dl_release_l2l3(struct layer2 *l2)
l2up_create(l2, pr, 0, NULL);
}
-inline void
+static inline void
lapb_dl_release_l2l3(struct layer2 *l2, int f)
{
if (test_bit(FLG_LAPB, &l2->flag))
@@ -1129,7 +1120,7 @@ enquiry_cr(struct layer2 *l2, u_char typ, u_char cr, u_char pf)
enqueue_super(l2, skb);
}
-inline void
+static inline void
enquiry_response(struct layer2 *l2)
{
if (test_bit(FLG_OWN_BUSY, &l2->flag))
@@ -1139,7 +1130,7 @@ enquiry_response(struct layer2 *l2)
test_and_clear_bit(FLG_ACK_PEND, &l2->flag);
}
-inline void
+static inline void
transmit_enquiry(struct layer2 *l2)
{
if (test_bit(FLG_OWN_BUSY, &l2->flag))
--
1.7.9.5
^ permalink raw reply related
* [PATCH 17/26] drivers: isdn: Move prototype declaration to header file platform.h from divasi.c
From: Rashika Kheria @ 2014-02-07 12:39 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declarations of functions to header file
hardware/eicon/platform.h because they are used by more than one file.
This eliminates the following warnings in hardware/eicon/idifunc.c:
drivers/isdn/hardware/eicon/idifunc.c:243:12: warning: no previous prototype for ‘idifunc_init’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/idifunc.c:263:13: warning: no previous prototype for ‘idifunc_finit’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/divasi.c | 3 ---
drivers/isdn/hardware/eicon/platform.h | 3 +++
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/divasi.c b/drivers/isdn/hardware/eicon/divasi.c
index 4103a8c..c2a6f1a 100644
--- a/drivers/isdn/hardware/eicon/divasi.c
+++ b/drivers/isdn/hardware/eicon/divasi.c
@@ -48,9 +48,6 @@ static char *DRIVERLNAME = "diva_idi";
static char *DEVNAME = "DivasIDI";
char *DRIVERRELEASE_IDI = "2.0";
-extern int idifunc_init(void);
-extern void idifunc_finit(void);
-
/*
* helper functions
*/
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index f170e21..33d6be1 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -179,6 +179,9 @@ static __inline__ void diva_os_free(unsigned long flags, void *ptr)
vfree(ptr);
}
+int idifunc_init(void);
+void idifunc_finit(void);
+
/*
** use skbuffs for message buffer
*/
--
1.7.9.5
^ permalink raw reply related
* [PATCH 16/26] drivers: isdn: Move prototype declarations to appropriate header file hscx.h from elsa_ser.c
From: Rashika Kheria @ 2014-02-07 12:38 UTC (permalink / raw)
To: linux-kernel
Cc: Karsten Keil, Andrew Morton, David S. Miller, Kees Cook, netdev,
josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declarations of functions to header file hisax/hscx.h
because they are used by more than one file.
This eliminates the following warnings in hisax/hscx.c:
drivers/isdn/hisax/hscx.c:96:1: warning: no previous prototype for ‘hscx_l2l1’ [-Wmissing-prototypes]
drivers/isdn/hisax/hscx.c:175:1: warning: no previous prototype for ‘open_hscxstate’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hisax/elsa_ser.c | 2 --
drivers/isdn/hisax/hscx.h | 2 ++
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/isdn/hisax/elsa_ser.c b/drivers/isdn/hisax/elsa_ser.c
index 3f84dd8..0d5ccd2 100644
--- a/drivers/isdn/hisax/elsa_ser.c
+++ b/drivers/isdn/hisax/elsa_ser.c
@@ -419,9 +419,7 @@ static void rs_interrupt_elsa(struct IsdnCardState *cs)
#endif
}
-extern int open_hscxstate(struct IsdnCardState *cs, struct BCState *bcs);
extern void modehscx(struct BCState *bcs, int mode, int bc);
-extern void hscx_l2l1(struct PStack *st, int pr, void *arg);
static void
close_elsastate(struct BCState *bcs)
diff --git a/drivers/isdn/hisax/hscx.h b/drivers/isdn/hisax/hscx.h
index 1148b4b..e99db24 100644
--- a/drivers/isdn/hisax/hscx.h
+++ b/drivers/isdn/hisax/hscx.h
@@ -39,3 +39,5 @@ extern void modehscx(struct BCState *bcs, int mode, int bc);
extern void clear_pending_hscx_ints(struct IsdnCardState *cs);
extern void inithscx(struct IsdnCardState *cs);
extern void inithscxisac(struct IsdnCardState *cs, int part);
+extern void hscx_l2l1(struct PStack *st, int pr, void *arg);
+extern int open_hscxstate(struct IsdnCardState *cs, struct BCState *bcs);
--
1.7.9.5
^ permalink raw reply related
* [PATCH 15/26] drivers: isdn: Mark function as static in mISDNipac.c
From: Rashika Kheria @ 2014-02-07 12:37 UTC (permalink / raw)
To: linux-kernel; +Cc: Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Mark functions as static in hardware/mISDN/mISDNipac.c because they are
not used outside this file.
This elimiantes the following warnings in hardware/mISDN/mISDNipac.c:
drivers/isdn/hardware/mISDN/mISDNipac.c:116:1: warning: no previous prototype for ‘isac_empty_fifo’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/mISDN/mISDNipac.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/isdn/hardware/mISDN/mISDNipac.c b/drivers/isdn/hardware/mISDN/mISDNipac.c
index ccd7d85..e139abc 100644
--- a/drivers/isdn/hardware/mISDN/mISDNipac.c
+++ b/drivers/isdn/hardware/mISDN/mISDNipac.c
@@ -112,7 +112,7 @@ isac_ph_state_bh(struct dchannel *dch)
pr_debug("%s: TE newstate %x\n", isac->name, dch->state);
}
-void
+static void
isac_empty_fifo(struct isac_hw *isac, int count)
{
u8 *ptr;
--
1.7.9.5
^ permalink raw reply related
* [PATCH 14/26] drivers: isdn: Mark function as static in w6692.c
From: Rashika Kheria @ 2014-02-07 12:36 UTC (permalink / raw)
To: linux-kernel; +Cc: Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Mark functions as static in hardware/mISDN/w6692.c because they ar enot
used outside this file.
This eliminates the following warnings in hardware/mISDN/w6692.c:
drivers/isdn/hardware/mISDN/w6692.c:851:6: warning: no previous prototype for ‘initW6692’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/mISDN/w6692.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/isdn/hardware/mISDN/w6692.c b/drivers/isdn/hardware/mISDN/w6692.c
index de69f68..2e24a05 100644
--- a/drivers/isdn/hardware/mISDN/w6692.c
+++ b/drivers/isdn/hardware/mISDN/w6692.c
@@ -848,7 +848,7 @@ dbusy_timer_handler(struct dchannel *dch)
}
}
-void initW6692(struct w6692_hw *card)
+static void initW6692(struct w6692_hw *card)
{
u8 val;
--
1.7.9.5
^ permalink raw reply related
* [PATCH 13/26] drivers: isdn: Mark functions as static in avmfritz.c
From: Rashika Kheria @ 2014-02-07 12:35 UTC (permalink / raw)
To: linux-kernel; +Cc: Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Mark functions as static in hardware/mISDN/avmfritz.c because they are
not used outside this file.
This eliminates the following warnings in hardware/mISDN/avmfritz.c:
drivers/isdn/hardware/mISDN/avmfritz.c:288:1: warning: no previous prototype for ‘write_ctrl’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/avmfritz.c:745:1: warning: no previous prototype for ‘clear_pending_hdlc_ints’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/avmfritz.c:966:1: warning: no previous prototype for ‘setup_fritz’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/mISDN/avmfritz.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/isdn/hardware/mISDN/avmfritz.c b/drivers/isdn/hardware/mISDN/avmfritz.c
index 292991c..e3fa1cd 100644
--- a/drivers/isdn/hardware/mISDN/avmfritz.c
+++ b/drivers/isdn/hardware/mISDN/avmfritz.c
@@ -284,7 +284,7 @@ __write_ctrl_pciv2(struct fritzcard *fc, struct hdlc_hw *hdlc, u32 channel) {
AVM_HDLC_STATUS_1));
}
-void
+static void
write_ctrl(struct bchannel *bch, int which) {
struct fritzcard *fc = bch->hw;
struct hdlc_hw *hdlc;
@@ -741,7 +741,7 @@ inithdlc(struct fritzcard *fc)
modehdlc(&fc->bch[1], -1);
}
-void
+static void
clear_pending_hdlc_ints(struct fritzcard *fc)
{
u32 val;
@@ -962,7 +962,7 @@ avm_dctrl(struct mISDNchannel *ch, u32 cmd, void *arg)
return err;
}
-int
+static int
setup_fritz(struct fritzcard *fc)
{
u32 val, ver;
--
1.7.9.5
^ permalink raw reply related
* [PATCH 12/26] drivers: isdn: Mark functions as static and remove unused function in hfcmulti.c
From: Rashika Kheria @ 2014-02-07 12:34 UTC (permalink / raw)
To: linux-kernel; +Cc: Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Mark functions as static in hardware/mISDN/hfcmulti.c because they are
not used outside this file. Remove unused function from
hardware/mISDN/hfcmulti.c.
This eliminates the following warnings in hardware/mISDN/hfcmulti.c:
drivers/isdn/hardware/mISDN/hfcmulti.c:568:1: warning: no previous prototype for ‘enablepcibridge’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:574:1: warning: no previous prototype for ‘disablepcibridge’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:580:1: warning: no previous prototype for ‘readpcibridge’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:608:1: warning: no previous prototype for ‘writepcibridge’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:638:1: warning: no previous prototype for ‘cpld_set_reg’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:645:1: warning: no previous prototype for ‘cpld_write_reg’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:657:1: warning: no previous prototype for ‘cpld_read_reg’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:674:1: warning: no previous prototype for ‘vpm_write_address’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:681:1: warning: no previous prototype for ‘vpm_read_address’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:695:1: warning: no previous prototype for ‘vpm_in’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:716:1: warning: no previous prototype for ‘vpm_out’ [-Wmissing-prototypes]
drivers/isdn/hardware/mISDN/hfcmulti.c:1028:1: warning: no previous prototype for ‘plxsd_checksync’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/mISDN/hfcmulti.c | 36 ++++++++++----------------------
1 file changed, 11 insertions(+), 25 deletions(-)
diff --git a/drivers/isdn/hardware/mISDN/hfcmulti.c b/drivers/isdn/hardware/mISDN/hfcmulti.c
index 28543d7..0c4021d 100644
--- a/drivers/isdn/hardware/mISDN/hfcmulti.c
+++ b/drivers/isdn/hardware/mISDN/hfcmulti.c
@@ -564,19 +564,19 @@ disable_hwirq(struct hfc_multi *hc)
#define MAX_TDM_CHAN 32
-inline void
+static inline void
enablepcibridge(struct hfc_multi *c)
{
HFC_outb(c, R_BRG_PCM_CFG, (0x0 << 6) | 0x3); /* was _io before */
}
-inline void
+static inline void
disablepcibridge(struct hfc_multi *c)
{
HFC_outb(c, R_BRG_PCM_CFG, (0x0 << 6) | 0x2); /* was _io before */
}
-inline unsigned char
+static inline unsigned char
readpcibridge(struct hfc_multi *hc, unsigned char address)
{
unsigned short cipv;
@@ -604,7 +604,7 @@ readpcibridge(struct hfc_multi *hc, unsigned char address)
return data;
}
-inline void
+static inline void
writepcibridge(struct hfc_multi *hc, unsigned char address, unsigned char data)
{
unsigned short cipv;
@@ -634,14 +634,14 @@ writepcibridge(struct hfc_multi *hc, unsigned char address, unsigned char data)
outl(datav, hc->pci_iobase);
}
-inline void
+static inline void
cpld_set_reg(struct hfc_multi *hc, unsigned char reg)
{
/* Do data pin read low byte */
HFC_outb(hc, R_GPIO_OUT1, reg);
}
-inline void
+static inline void
cpld_write_reg(struct hfc_multi *hc, unsigned char reg, unsigned char val)
{
cpld_set_reg(hc, reg);
@@ -653,7 +653,7 @@ cpld_write_reg(struct hfc_multi *hc, unsigned char reg, unsigned char val)
return;
}
-inline unsigned char
+static inline unsigned char
cpld_read_reg(struct hfc_multi *hc, unsigned char reg)
{
unsigned char bytein;
@@ -670,28 +670,14 @@ cpld_read_reg(struct hfc_multi *hc, unsigned char reg)
return bytein;
}
-inline void
+static inline void
vpm_write_address(struct hfc_multi *hc, unsigned short addr)
{
cpld_write_reg(hc, 0, 0xff & addr);
cpld_write_reg(hc, 1, 0x01 & (addr >> 8));
}
-inline unsigned short
-vpm_read_address(struct hfc_multi *c)
-{
- unsigned short addr;
- unsigned short highbit;
-
- addr = cpld_read_reg(c, 0);
- highbit = cpld_read_reg(c, 1);
-
- addr = addr | (highbit << 8);
-
- return addr & 0x1ff;
-}
-
-inline unsigned char
+static inline unsigned char
vpm_in(struct hfc_multi *c, int which, unsigned short addr)
{
unsigned char res;
@@ -712,7 +698,7 @@ vpm_in(struct hfc_multi *c, int which, unsigned short addr)
return res;
}
-inline void
+static inline void
vpm_out(struct hfc_multi *c, int which, unsigned short addr,
unsigned char data)
{
@@ -1024,7 +1010,7 @@ hfcmulti_resync(struct hfc_multi *locked, struct hfc_multi *newmaster, int rm)
}
/* This must be called AND hc must be locked irqsave!!! */
-inline void
+static inline void
plxsd_checksync(struct hfc_multi *hc, int rm)
{
if (hc->syncronized) {
--
1.7.9.5
^ permalink raw reply related
* [PATCH 11/26] drivers: isdn: Move prototype declarations to header file platform.h from mntfunc.c
From: Rashika Kheria @ 2014-02-07 12:33 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declarations of functions to header file
hardware/eicon/platform.h because they are used by more than one file.
This eliminates the following warnings in hardware/eicon/divamnt.c:
drivers/isdn/hardware/eicon/divamnt.c:75:5: warning: no previous prototype for ‘diva_os_copy_to_user’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/divamnt.c:80:5: warning: no previous prototype for ‘diva_os_copy_from_user’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/mntfunc.c | 5 -----
drivers/isdn/hardware/eicon/platform.h | 9 +++++++++
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/mntfunc.c b/drivers/isdn/hardware/eicon/mntfunc.c
index 1cd9aff..e304a1d 100644
--- a/drivers/isdn/hardware/eicon/mntfunc.c
+++ b/drivers/isdn/hardware/eicon/mntfunc.c
@@ -29,11 +29,6 @@ static DESCRIPTOR MAdapter;
static DESCRIPTOR MaintDescriptor =
{ IDI_DIMAINT, 0, 0, (IDI_CALL) diva_maint_prtComp };
-extern int diva_os_copy_to_user(void *os_handle, void __user *dst,
- const void *src, int length);
-extern int diva_os_copy_from_user(void *os_handle, void *dst,
- const void __user *src, int length);
-
static void no_printf(unsigned char *x, ...)
{
/* dummy debug function */
diff --git a/drivers/isdn/hardware/eicon/platform.h b/drivers/isdn/hardware/eicon/platform.h
index ef329e0..f170e21 100644
--- a/drivers/isdn/hardware/eicon/platform.h
+++ b/drivers/isdn/hardware/eicon/platform.h
@@ -277,6 +277,15 @@ void diva_os_remove_soft_isr(diva_os_soft_isr_t *psoft_isr);
void diva_os_get_time(dword *sec, dword *usec);
/*
+ * kernel/user space copy functions
+ */
+int diva_os_copy_to_user(void *os_handle, void __user *dst,
+ const void *src, int length);
+int diva_os_copy_from_user(void *os_handle, void *dst,
+ const void __user *src, int length);
+
+
+/*
** atomic operation, fake because we use threads
*/
typedef int diva_os_atomic_t;
--
1.7.9.5
^ permalink raw reply related
* [PATCH 10/26] drivers: isdn: Move prototype declaration to appropriate header file diva.h
From: Rashika Kheria @ 2014-02-07 12:29 UTC (permalink / raw)
To: linux-kernel; +Cc: Armin Schindler, Karsten Keil, netdev, josh
In-Reply-To: <3cb4d7892ba5a0c0936b3a1e2c9c991a6dbc3229.1390408513.git.rashika.kheria@gmail.com>
Move prototype declarations of functions to header file
hardware/eicon/diva.h because they are used by more than one file. Also,
include appropriate header files while adding the prototypes.
This eliminates the following warnings in hardware/eicon/diva.c:
drivers/isdn/hardware/eicon/diva.c:516:13: warning: no previous prototype for ‘diva_os_irq_wrapper’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/diva.c:570:6: warning: no previous prototype for ‘diva_xdi_display_adapter_features’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/diva.c:606:6: warning: no previous prototype for ‘diva_add_slave_adapter’ [-Wmissing-prototypes]
drivers/isdn/hardware/eicon/diva.c:615:5: warning: no previous prototype for ‘diva_card_read_xlog’ [-Wmissing-prototypes]
Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
drivers/isdn/hardware/eicon/diva.h | 6 ++++++
drivers/isdn/hardware/eicon/divasmain.c | 3 +--
drivers/isdn/hardware/eicon/os_4bri.c | 5 +----
drivers/isdn/hardware/eicon/os_bri.c | 3 +--
drivers/isdn/hardware/eicon/os_pri.c | 3 +--
5 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/isdn/hardware/eicon/diva.h b/drivers/isdn/hardware/eicon/diva.h
index e979085..b2c070c 100644
--- a/drivers/isdn/hardware/eicon/diva.h
+++ b/drivers/isdn/hardware/eicon/diva.h
@@ -3,6 +3,8 @@
#ifndef __DIVA_XDI_OS_PART_H__
#define __DIVA_XDI_OS_PART_H__
+#include "xdi_msg.h"
+#include "xdi_adapter.h"
int divasa_xdi_driver_entry(void);
void divasa_xdi_driver_unload(void);
@@ -27,5 +29,9 @@ void *diva_xdi_open_adapter(void *os_handle, const void __user *src,
void diva_xdi_close_adapter(void *adapter, void *os_handle);
+irqreturn_t diva_os_irq_wrapper(int irq, void *context);
+void diva_xdi_display_adapter_features(int card);
+void diva_add_slave_adapter(diva_os_xdi_adapter_t *a);
+int diva_card_read_xlog(diva_os_xdi_adapter_t *a);
#endif
diff --git a/drivers/isdn/hardware/eicon/divasmain.c b/drivers/isdn/hardware/eicon/divasmain.c
index 83a788f..6b15670 100644
--- a/drivers/isdn/hardware/eicon/divasmain.c
+++ b/drivers/isdn/hardware/eicon/divasmain.c
@@ -27,7 +27,6 @@
#include "pc.h"
#include "di_defs.h"
#include "divasync.h"
-#include "diva.h"
#include "di.h"
#include "io.h"
#include "xdi_msg.h"
@@ -35,6 +34,7 @@
#include "xdi_vers.h"
#include "diva_dma.h"
#include "diva_pci.h"
+#include "diva.h"
static char *main_revision = "$Revision: 1.55.4.6 $";
@@ -55,7 +55,6 @@ static char *DRIVERLNAME = "divas";
static char *DEVNAME = "Divas";
char *DRIVERRELEASE_DIVAS = "2.0";
-extern irqreturn_t diva_os_irq_wrapper(int irq, void *context);
extern int create_divas_proc(void);
extern void remove_divas_proc(void);
diff --git a/drivers/isdn/hardware/eicon/os_4bri.c b/drivers/isdn/hardware/eicon/os_4bri.c
index 1891246..54f7033 100644
--- a/drivers/isdn/hardware/eicon/os_4bri.c
+++ b/drivers/isdn/hardware/eicon/os_4bri.c
@@ -17,6 +17,7 @@
#include "mi_pc.h"
#include "dsrv4bri.h"
#include "helpers.h"
+#include "diva.h"
static void *diva_xdiLoadFileFile = NULL;
static dword diva_xdiLoadFileLength = 0;
@@ -26,14 +27,10 @@ static dword diva_xdiLoadFileLength = 0;
*/
extern void prepare_qBri_functions(PISDN_ADAPTER IoAdapter);
extern void prepare_qBri2_functions(PISDN_ADAPTER IoAdapter);
-extern void diva_xdi_display_adapter_features(int card);
-extern void diva_add_slave_adapter(diva_os_xdi_adapter_t *a);
extern int qBri_FPGA_download(PISDN_ADAPTER IoAdapter);
extern void start_qBri_hardware(PISDN_ADAPTER IoAdapter);
-extern int diva_card_read_xlog(diva_os_xdi_adapter_t *a);
-
/*
** LOCALS
*/
diff --git a/drivers/isdn/hardware/eicon/os_bri.c b/drivers/isdn/hardware/eicon/os_bri.c
index 20f2653..c7a45e6 100644
--- a/drivers/isdn/hardware/eicon/os_bri.c
+++ b/drivers/isdn/hardware/eicon/os_bri.c
@@ -17,13 +17,12 @@
#include "mi_pc.h"
#include "pc_maint.h"
#include "dsrv_bri.h"
+#include "diva.h"
/*
** IMPORTS
*/
extern void prepare_maestra_functions(PISDN_ADAPTER IoAdapter);
-extern void diva_xdi_display_adapter_features(int card);
-extern int diva_card_read_xlog(diva_os_xdi_adapter_t *a);
/*
** LOCALS
diff --git a/drivers/isdn/hardware/eicon/os_pri.c b/drivers/isdn/hardware/eicon/os_pri.c
index da4957a..acc1de6 100644
--- a/drivers/isdn/hardware/eicon/os_pri.c
+++ b/drivers/isdn/hardware/eicon/os_pri.c
@@ -19,6 +19,7 @@
#include "dsp_tst.h"
#include "diva_dma.h"
#include "dsrv_pri.h"
+#include "diva.h"
/* --------------------------------------------------------------------------
OS Dependent part of XDI driver for DIVA PRI Adapter
@@ -28,14 +29,12 @@
#define DIVA_PRI_NO_PCI_BIOS_WORKAROUND 1
-extern int diva_card_read_xlog(diva_os_xdi_adapter_t *a);
/*
** IMPORTS
*/
extern void prepare_pri_functions(PISDN_ADAPTER IoAdapter);
extern void prepare_pri2_functions(PISDN_ADAPTER IoAdapter);
-extern void diva_xdi_display_adapter_features(int card);
static int diva_pri_cleanup_adapter(diva_os_xdi_adapter_t *a);
static int diva_pri_cmd_card_proc(struct _diva_os_xdi_adapter *a,
--
1.7.9.5
^ permalink raw reply related
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox