Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 360d26e4 authored by Sachin Kamat's avatar Sachin Kamat Committed by Greg Kroah-Hartman
Browse files

staging: cxt1e1: pmcc4_drv.c: Use NULL instead of 0



Pointers should be assigned NULL instead of 0.

Signed-off-by: default avatarSachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c11afaae
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@ extern void *memset (void *s, int c, size_t n);
#endif

int         drvr_state = SBE_DRVR_INIT;
ci_t       *c4_list = 0;
ci_t       *c4_list = NULL;
ci_t       *CI;                 /* dummy pointer to board ZEROE's data -
                                 * DEBUG USAGE */

@@ -119,7 +119,7 @@ c4_find_chan (int channum)
                        return ch;
                }
            }
    return 0;
    return NULL;
}


@@ -145,7 +145,7 @@ c4_new (void *hi)
        pr_warning("failed CI malloc, size %u.\n",
                   (unsigned int) sizeof (ci_t));

    if (CI == 0)
    if (!CI)
        CI = ci;                    /* DEBUG, only board 0 usage */
    return ci;
}
@@ -831,7 +831,7 @@ c4_musycc_rw (ci_t *ci, struct c4_musycc_param *mcp)
{
    mpi_t      *pi;
    volatile u_int32_t *dph;    /* hardware implemented register */
    u_int32_t  *dpr = 0;        /* RAM image of registers for group command
    u_int32_t *dpr = NULL;	/* RAM image of registers for group command
                                 * usage */
    int         offset = mcp->offset % 0x800;   /* group relative address
                                                 * offset, mcp->portnum is
@@ -1060,7 +1060,7 @@ c4_new_chan (ci_t *ci, int portnum, int channum, void *user)
    }

    /* save off interface assignments which bound a board */
    if (ci->first_if == 0)          /* first channel registered is assumed to
    if (!ci->first_if)		/* first channel registered is assumed to
                                     * be the lowest channel */
    {
        ci->first_if = ci->last_if = user;
@@ -1392,7 +1392,7 @@ c4_chan_up (ci_t *ci, int channum)
        md->status = HOST_TX_OWNED; /* Host owns TX descriptor ** CODING
                                     * NOTE: HOST_TX_OWNED = 0 so no need to
                                     * byteSwap */
        md->mem_token = 0;
        md->mem_token = NULL;
        md->data = 0;
        if (i == (txnum - 1))
        {
@@ -1448,10 +1448,10 @@ c4_chan_up (ci_t *ci, int channum)
        OS_mem_token_free (ch->mdr[i].mem_token);
    }
    OS_kfree (ch->mdt);
    ch->mdt = 0;
    ch->mdt = NULL;
    ch->txd_num = 0;
    OS_kfree (ch->mdr);
    ch->mdr = 0;
    ch->mdr = NULL;
    ch->rxd_num = 0;
    ch->state = DOWN;
    return ENOBUFS;