xpp: style - Remove 0/NULL static initializers
* Applied via: perl -pi -e 's/(\bstatic\b[^=]*?)\s*=\s*(0|NULL)\s*;/$1;/' "$@" Signed-off-by: Oron Peled <oron.peled@xorcom.com> Acked-By: Tzafrir Cohen <tzafrir.cohen@xorcom.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@10423 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
parent
535ef8086c
commit
c7946df16e
@ -984,7 +984,7 @@ static int FXS_card_ioctl(xpd_t *xpd, int pos, unsigned int cmd, unsigned long a
|
|||||||
if (get_user(val, (int __user *)arg))
|
if (get_user(val, (int __user *)arg))
|
||||||
return -EFAULT;
|
return -EFAULT;
|
||||||
if(!vmwi_ioctl) {
|
if(!vmwi_ioctl) {
|
||||||
static bool notified = 0;
|
static bool notified;
|
||||||
|
|
||||||
if(!notified++)
|
if(!notified++)
|
||||||
LINE_NOTICE(xpd, pos,
|
LINE_NOTICE(xpd, pos,
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
#include <linux/parport.h>
|
#include <linux/parport.h>
|
||||||
#include "parport_debug.h"
|
#include "parport_debug.h"
|
||||||
|
|
||||||
static struct parport *debug_sync_parport = NULL;
|
static struct parport *debug_sync_parport;
|
||||||
static int parport_toggles[8]; /* 8 bit flip-flop */
|
static int parport_toggles[8]; /* 8 bit flip-flop */
|
||||||
|
|
||||||
void flip_parport_bit(unsigned char bitnum)
|
void flip_parport_bit(unsigned char bitnum)
|
||||||
|
@ -73,7 +73,7 @@ static void transport_destroy(xbus_t *xbus);
|
|||||||
/* Data structures */
|
/* Data structures */
|
||||||
static DEFINE_SPINLOCK(xbuses_lock);
|
static DEFINE_SPINLOCK(xbuses_lock);
|
||||||
#ifdef CONFIG_PROC_FS
|
#ifdef CONFIG_PROC_FS
|
||||||
static struct proc_dir_entry *proc_xbuses = NULL;
|
static struct proc_dir_entry *proc_xbuses;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static struct xbus_desc {
|
static struct xbus_desc {
|
||||||
|
@ -54,10 +54,10 @@ static struct xpp_ticker dahdi_ticker;
|
|||||||
* The ref_ticker points to the current referece tick source.
|
* The ref_ticker points to the current referece tick source.
|
||||||
* I.e: one of our AB or dahdi_ticker
|
* I.e: one of our AB or dahdi_ticker
|
||||||
*/
|
*/
|
||||||
static struct xpp_ticker *ref_ticker = NULL;
|
static struct xpp_ticker *ref_ticker;
|
||||||
static DEFINE_SPINLOCK(ref_ticker_lock);
|
static DEFINE_SPINLOCK(ref_ticker_lock);
|
||||||
static DEFINE_SPINLOCK(elect_syncer_lock);
|
static DEFINE_SPINLOCK(elect_syncer_lock);
|
||||||
static bool force_dahdi_sync = 0; /* from /sys/bus/astribanks/drivers/xppdrv/sync */
|
static bool force_dahdi_sync; /* from /sys/bus/astribanks/drivers/xppdrv/sync */
|
||||||
static xbus_t *global_ticker;
|
static xbus_t *global_ticker;
|
||||||
static struct xpp_ticker global_ticks_series;
|
static struct xpp_ticker global_ticks_series;
|
||||||
|
|
||||||
@ -80,7 +80,7 @@ static struct xpp_ticker global_ticks_series;
|
|||||||
#define SYNC_ADJ_SLOW 10000
|
#define SYNC_ADJ_SLOW 10000
|
||||||
|
|
||||||
#ifdef DAHDI_SYNC_TICK
|
#ifdef DAHDI_SYNC_TICK
|
||||||
static unsigned int dahdi_tick_count = 0;
|
static unsigned int dahdi_tick_count;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*------------------------- SYNC Handling --------------------------*/
|
/*------------------------- SYNC Handling --------------------------*/
|
||||||
@ -795,7 +795,7 @@ static bool pcm_valid(xpd_t *xpd, xpacket_t *pack)
|
|||||||
/* FRAMES: include opcode in calculation */
|
/* FRAMES: include opcode in calculation */
|
||||||
good_len = RPACKET_HEADERSIZE + sizeof(xpp_line_t) + count * 8;
|
good_len = RPACKET_HEADERSIZE + sizeof(xpp_line_t) + count * 8;
|
||||||
if(XPACKET_LEN(pack) != good_len) {
|
if(XPACKET_LEN(pack) != good_len) {
|
||||||
static int rate_limit = 0;
|
static int rate_limit;
|
||||||
|
|
||||||
XPD_COUNTER(xpd, RECV_ERRORS)++;
|
XPD_COUNTER(xpd, RECV_ERRORS)++;
|
||||||
if((rate_limit++ % 1000) <= 10) {
|
if((rate_limit++ % 1000) <= 10) {
|
||||||
|
@ -48,7 +48,7 @@ static void __xframe_dump_queue(struct xframe_queue *q)
|
|||||||
static bool __xframe_enqueue(struct xframe_queue *q, xframe_t *xframe)
|
static bool __xframe_enqueue(struct xframe_queue *q, xframe_t *xframe)
|
||||||
{
|
{
|
||||||
int ret = 1;
|
int ret = 1;
|
||||||
static int overflow_cnt = 0;
|
static int overflow_cnt;
|
||||||
|
|
||||||
if(unlikely(q->disabled)) {
|
if(unlikely(q->disabled)) {
|
||||||
ret = 0;
|
ret = 0;
|
||||||
|
@ -836,7 +836,7 @@ int xpp_maint(struct dahdi_span *span, int cmd)
|
|||||||
*/
|
*/
|
||||||
static int xpp_watchdog(struct dahdi_span *span, int cause)
|
static int xpp_watchdog(struct dahdi_span *span, int cause)
|
||||||
{
|
{
|
||||||
static int rate_limit = 0;
|
static int rate_limit;
|
||||||
|
|
||||||
if((rate_limit++ % 1000) == 0)
|
if((rate_limit++ % 1000) == 0)
|
||||||
DBG(GENERAL, "\n");
|
DBG(GENERAL, "\n");
|
||||||
|
@ -167,7 +167,7 @@ static struct xusb_counters {
|
|||||||
|
|
||||||
#define MAX_PENDING_WRITES 100
|
#define MAX_PENDING_WRITES 100
|
||||||
|
|
||||||
static KMEM_CACHE_T *xusb_cache = NULL;
|
static KMEM_CACHE_T *xusb_cache;
|
||||||
|
|
||||||
typedef struct xusb xusb_t;
|
typedef struct xusb xusb_t;
|
||||||
|
|
||||||
@ -243,7 +243,7 @@ struct xusb {
|
|||||||
|
|
||||||
static DEFINE_SPINLOCK(xusb_lock);
|
static DEFINE_SPINLOCK(xusb_lock);
|
||||||
static xusb_t *xusb_array[MAX_BUSES] = {};
|
static xusb_t *xusb_array[MAX_BUSES] = {};
|
||||||
static unsigned bus_count = 0;
|
static unsigned bus_count;
|
||||||
|
|
||||||
|
|
||||||
/* prevent races between open() and disconnect() */
|
/* prevent races between open() and disconnect() */
|
||||||
|
@ -317,7 +317,7 @@ void dump_packet(const char *msg, const xpacket_t *packet, bool debug)
|
|||||||
|
|
||||||
printk(" BYTES: ");
|
printk(" BYTES: ");
|
||||||
for(i = 0; i < XPACKET_LEN(packet); i++) {
|
for(i = 0; i < XPACKET_LEN(packet); i++) {
|
||||||
static int limiter = 0;
|
static int limiter;
|
||||||
|
|
||||||
if(i >= sizeof(xpacket_t)) {
|
if(i >= sizeof(xpacket_t)) {
|
||||||
if(limiter < ERR_REPORT_LIMIT) {
|
if(limiter < ERR_REPORT_LIMIT) {
|
||||||
|
Loading…
Reference in New Issue
Block a user