get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/823510/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 823510,
    "url": "http://patchwork.ozlabs.org/api/patches/823510/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/netdev/patch/bdd41a34-143a-b075-dca8-e43199abdbd1@users.sourceforge.net/",
    "project": {
        "id": 7,
        "url": "http://patchwork.ozlabs.org/api/projects/7/?format=api",
        "name": "Linux network development",
        "link_name": "netdev",
        "list_id": "netdev.vger.kernel.org",
        "list_email": "netdev@vger.kernel.org",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<bdd41a34-143a-b075-dca8-e43199abdbd1@users.sourceforge.net>",
    "list_archive_url": null,
    "date": "2017-10-09T20:52:22",
    "name": "[3/3] net/atm: Adjust 121 checks for null pointers",
    "commit_ref": null,
    "pull_url": null,
    "state": "rejected",
    "archived": true,
    "hash": "0ab0cafc3389fbf7822ec281c83e7847342be553",
    "submitter": {
        "id": 65077,
        "url": "http://patchwork.ozlabs.org/api/people/65077/?format=api",
        "name": "SF Markus Elfring",
        "email": "elfring@users.sourceforge.net"
    },
    "delegate": {
        "id": 34,
        "url": "http://patchwork.ozlabs.org/api/users/34/?format=api",
        "username": "davem",
        "first_name": "David",
        "last_name": "Miller",
        "email": "davem@davemloft.net"
    },
    "mbox": "http://patchwork.ozlabs.org/project/netdev/patch/bdd41a34-143a-b075-dca8-e43199abdbd1@users.sourceforge.net/mbox/",
    "series": [
        {
            "id": 7242,
            "url": "http://patchwork.ozlabs.org/api/series/7242/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/netdev/list/?series=7242",
            "date": "2017-10-09T20:48:11",
            "name": "net-ATM: Adjustments for several function implementations",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/7242/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/823510/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/823510/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<netdev-owner@vger.kernel.org>",
        "X-Original-To": "patchwork-incoming@ozlabs.org",
        "Delivered-To": "patchwork-incoming@ozlabs.org",
        "Authentication-Results": "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=vger.kernel.org\n\t(client-ip=209.132.180.67; helo=vger.kernel.org;\n\tenvelope-from=netdev-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)",
        "Received": [
            "from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 3y9ssF037cz9sRq\n\tfor <patchwork-incoming@ozlabs.org>;\n\tTue, 10 Oct 2017 07:53:21 +1100 (AEDT)",
            "(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1755095AbdJIUwy (ORCPT <rfc822;patchwork-incoming@ozlabs.org>);\n\tMon, 9 Oct 2017 16:52:54 -0400",
            "from mout.web.de ([217.72.192.78]:51092 \"EHLO mout.web.de\"\n\trhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP\n\tid S1754373AbdJIUww (ORCPT <rfc822;netdev@vger.kernel.org>);\n\tMon, 9 Oct 2017 16:52:52 -0400",
            "from [192.168.1.2] ([77.181.206.143]) by smtp.web.de (mrweb103\n\t[213.165.67.124]) with ESMTPSA (Nemesis) id 0LwqJw-1dCqiC0REe-016MM7;\n\tMon, 09 Oct 2017 22:52:28 +0200"
        ],
        "Subject": "[PATCH 3/3] net/atm: Adjust 121 checks for null pointers",
        "From": "SF Markus Elfring <elfring@users.sourceforge.net>",
        "To": "netdev@vger.kernel.org, Alexey Dobriyan <adobriyan@gmail.com>,\n\tAndrew Morton <akpm@linux-foundation.org>,\n\tAugusto Mecking Caringi <augustocaringi@gmail.com>,\n\tBhumika Goyal <bhumirks@gmail.com>,\n\t\"David S. Miller\" <davem@davemloft.net>,\n\tDavid Windsor <dwindsor@gmail.com>,\n\tElena Reshetova <elena.reshetova@intel.com>,\n\tHans Liljestrand <ishkamiel@gmail.com>, Jarod Wilson <jarod@redhat.com>,\n\tJohannes Berg <johannes.berg@intel.com>,\n\tKees Cook <keescook@chromium.org>, Mitchell Blank Jr <mitch@sfgoth.com>,\n\tRoopa Prabhu <roopa@cumulusnetworks.com>",
        "Cc": "LKML <linux-kernel@vger.kernel.org>, kernel-janitors@vger.kernel.org",
        "References": "<10a92558-1105-b947-86a2-6ac763cca36d@users.sourceforge.net>",
        "Message-ID": "<bdd41a34-143a-b075-dca8-e43199abdbd1@users.sourceforge.net>",
        "Date": "Mon, 9 Oct 2017 22:52:22 +0200",
        "User-Agent": "Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101\n\tThunderbird/52.3.0",
        "MIME-Version": "1.0",
        "In-Reply-To": "<10a92558-1105-b947-86a2-6ac763cca36d@users.sourceforge.net>",
        "Content-Type": "text/plain; charset=utf-8",
        "Content-Language": "en-GB",
        "Content-Transfer-Encoding": "8bit",
        "X-Provags-ID": "V03:K0:KwaYsnIF5quTDap4tbrQNf3FYO7obKSzI0P0ddfGcF5UHqCbQfD\n\t3p4Z6QJQakwsveczq7sPbwmf2ZQTJq5JgYNylk7vB0ZKz1Lo/QZR1o57BTyg3uFbXD4GhYc\n\ttbgfZ8xviWP0CsSajDev/+LdRCmk6SqM4vnThAjUkXx7sxvsAVH9YEeqTWSyhGk/F2Ele/g\n\t8v+GyOjwJp0PUaREdiHiA==",
        "X-UI-Out-Filterresults": "notjunk:1; V01:K0:ut4p6HKLEKg=:5CO73npBIu2eg/zwNQhQ1v\n\tWdpYyvjR3sReiPTQWn5EOGXyfVn6h3MOA830dlsdWwGPdg6W8RgcwBVBITN+PBN5Igqqe5H6z\n\tWrg9ZsPGF5hyf0vFE3/wAe8jtcra3osCK1CWmKGPZiaI9NlGmov6sSIcQuykop9ZxGFfsl2Zy\n\tRJTAvck/3TsG/3YE8MYkcGFAz9O7e84XukCQOU4dtZBFuh8Ay3elEe44mio68QP7+i2lh9HTb\n\tW7fU2t318ulqYuy+waT6MGgevSGF5qNrcDwrag4ZebKfccYnyZ4eCOBx+7EDrp+suQ+tazjQ6\n\tRmq0AuNPfea3o6pLlPGpDzrnxFZj2JSDIis1TfBfFEfohKKxFWCnUQC/mYGJi9GXdBI9CMzsM\n\tjXOssn08mBKEaSopNeSgsoWj64siwPrGjs4Ozd22lzP7c/En9tY3+eXMLMLSKOYk+RqKAIOhN\n\tXUlXeCM8i6wijGXMsejdk6F77QkMsZKs4IFxhBE40+ldmnE3wfsnR/hVaqA0EvgZheGLgCYPV\n\tWOreX7Pr4yPAVhNO7CzxtRJtxwUEw6mOs6isAUzh9T1dM/ubI0S981JCPQrP14AkqI2jq48PJ\n\t95scaEuzh/WB6JPschvCaqKfqO062cgIQtnmc910mWOaRORUi7ceHog3I/Oway0u5FOQEIdnq\n\tg4tFstsPxG22xVr42yekYe3yvZJyI9jLxPfWgX3UIIkalnunjhnfazMNP/hqp0JqCLyXc3HZa\n\t5quLWyPIIur/ZHKpOMjaiYZyt/z2DPGgLMLCQc1wkyqRognaI9aOGxEerLIfYt3toe34B7vod\n\tjdax1mnu5a2wAcq33Ww+8f/ErP9S92Gye7IVo+WzUjHJqxhY5k=",
        "Sender": "netdev-owner@vger.kernel.org",
        "Precedence": "bulk",
        "List-ID": "<netdev.vger.kernel.org>",
        "X-Mailing-List": "netdev@vger.kernel.org"
    },
    "content": "From: Markus Elfring <elfring@users.sourceforge.net>\nDate: Mon, 9 Oct 2017 22:22:45 +0200\nMIME-Version: 1.0\nContent-Type: text/plain; charset=UTF-8\nContent-Transfer-Encoding: 8bit\n\nThe script “checkpatch.pl” pointed information out like the following.\n\nComparison to NULL could be written …\n\nThus fix the affected source code places.\n\nSigned-off-by: Markus Elfring <elfring@users.sourceforge.net>\n---\n net/atm/br2684.c      |  17 ++++----\n net/atm/clip.c        |   2 +-\n net/atm/lec.c         |  38 ++++++++---------\n net/atm/mpc.c         | 114 +++++++++++++++++++++++++-------------------------\n net/atm/mpoa_caches.c |  63 ++++++++++++++--------------\n net/atm/pppoatm.c     |  11 +++--\n net/atm/proc.c        |   2 +-\n 7 files changed, 123 insertions(+), 124 deletions(-)",
    "diff": "diff --git a/net/atm/br2684.c b/net/atm/br2684.c\nindex f5b601c01f38..d3f8ec90556a 100644\n--- a/net/atm/br2684.c\n+++ b/net/atm/br2684.c\n@@ -212,7 +212,7 @@ static int br2684_xmit_vcc(struct sk_buff *skb, struct net_device *dev,\n \t\tstruct sk_buff *skb2 = skb_realloc_headroom(skb, minheadroom);\n \t\tbrvcc->copies_needed++;\n \t\tdev_kfree_skb(skb);\n-\t\tif (skb2 == NULL) {\n+\t\tif (!skb2) {\n \t\t\tbrvcc->copies_failed++;\n \t\t\treturn 0;\n \t\t}\n@@ -299,7 +299,7 @@ static netdev_tx_t br2684_start_xmit(struct sk_buff *skb,\n \tpr_debug(\"skb_dst(skb)=%p\\n\", skb_dst(skb));\n \tread_lock(&devs_lock);\n \tbrvcc = pick_outgoing_vcc(skb, brdev);\n-\tif (brvcc == NULL) {\n+\tif (!brvcc) {\n \t\tpr_debug(\"no vcc attached to dev %s\\n\", dev->name);\n \t\tdev->stats.tx_errors++;\n \t\tdev->stats.tx_carrier_errors++;\n@@ -372,13 +372,13 @@ static int br2684_setfilt(struct atm_vcc *atmvcc, void __user * arg)\n \t\tstruct br2684_dev *brdev;\n \t\tread_lock(&devs_lock);\n \t\tbrdev = BRPRIV(br2684_find_dev(&fs.ifspec));\n-\t\tif (brdev == NULL || list_empty(&brdev->brvccs) ||\n+\t\tif (!brdev || list_empty(&brdev->brvccs) ||\n \t\t    brdev->brvccs.next != brdev->brvccs.prev)\t/* >1 VCC */\n \t\t\tbrvcc = NULL;\n \t\telse\n \t\t\tbrvcc = list_entry_brvcc(brdev->brvccs.next);\n \t\tread_unlock(&devs_lock);\n-\t\tif (brvcc == NULL)\n+\t\tif (!brvcc)\n \t\t\treturn -ESRCH;\n \t} else\n \t\tbrvcc = BR2684_VCC(atmvcc);\n@@ -427,8 +427,7 @@ static void br2684_push(struct atm_vcc *atmvcc, struct sk_buff *skb)\n \tstruct br2684_dev *brdev = BRPRIV(net_dev);\n \n \tpr_debug(\"\\n\");\n-\n-\tif (unlikely(skb == NULL)) {\n+\tif (unlikely(!skb)) {\n \t\t/* skb==NULL means VCC is being destroyed */\n \t\tbr2684_close_vcc(brvcc);\n \t\tif (list_empty(&brdev->brvccs)) {\n@@ -550,13 +549,13 @@ static int br2684_regvcc(struct atm_vcc *atmvcc, void __user * arg)\n \tatomic_set(&brvcc->qspace, 2);\n \twrite_lock_irq(&devs_lock);\n \tnet_dev = br2684_find_dev(&be.ifspec);\n-\tif (net_dev == NULL) {\n+\tif (!net_dev) {\n \t\tpr_err(\"tried to attach to non-existent device\\n\");\n \t\terr = -ENXIO;\n \t\tgoto error;\n \t}\n \tbrdev = BRPRIV(net_dev);\n-\tif (atmvcc->push == NULL) {\n+\tif (!atmvcc->push) {\n \t\terr = -EBADFD;\n \t\tgoto error;\n \t}\n@@ -839,7 +838,7 @@ static int __init br2684_init(void)\n #ifdef CONFIG_PROC_FS\n \tstruct proc_dir_entry *p;\n \tp = proc_create(\"br2684\", 0, atm_proc_root, &br2684_proc_ops);\n-\tif (p == NULL)\n+\tif (!p)\n \t\treturn -ENOMEM;\n #endif\n \tregister_atm_ioctl(&br2684_ioctl_ops);\ndiff --git a/net/atm/clip.c b/net/atm/clip.c\nindex 041d519b8771..b45bfcb6cc1b 100644\n--- a/net/atm/clip.c\n+++ b/net/atm/clip.c\n@@ -809,7 +809,7 @@ static void *clip_seq_vcc_walk(struct clip_seq_state *state,\n \tstruct clip_vcc *vcc = state->vcc;\n \n \tvcc = clip_seq_next_vcc(e, vcc);\n-\tif (vcc && pos != NULL) {\n+\tif (vcc && pos) {\n \t\twhile (*pos) {\n \t\t\tvcc = clip_seq_next_vcc(e, vcc);\n \t\t\tif (!vcc)\ndiff --git a/net/atm/lec.c b/net/atm/lec.c\nindex 74a794602412..4f94c6ed893c 100644\n--- a/net/atm/lec.c\n+++ b/net/atm/lec.c\n@@ -139,7 +139,7 @@ static void lec_handle_bridge(struct sk_buff *skb, struct net_device *dev)\n \t\tstruct atmlec_msg *mesg;\n \n \t\tskb2 = alloc_skb(sizeof(struct atmlec_msg), GFP_ATOMIC);\n-\t\tif (skb2 == NULL)\n+\t\tif (!skb2)\n \t\t\treturn;\n \t\tskb2->len = sizeof(struct atmlec_msg);\n \t\tmesg = (struct atmlec_msg *)skb2->data;\n@@ -264,7 +264,7 @@ static netdev_tx_t lec_start_xmit(struct sk_buff *skb,\n \t\t\t\t\t       min_frame_size - skb->truesize,\n \t\t\t\t\t       GFP_ATOMIC);\n \t\t\tdev_kfree_skb(skb);\n-\t\t\tif (skb2 == NULL) {\n+\t\t\tif (!skb2) {\n \t\t\t\tdev->stats.tx_dropped++;\n \t\t\t\treturn NETDEV_TX_OK;\n \t\t\t}\n@@ -431,7 +431,7 @@ static int lec_atm_send(struct atm_vcc *vcc, struct sk_buff *skb)\n \t\tpr_debug(\"%s: bridge zeppelin asks about %pM\\n\",\n \t\t\t dev->name, mesg->content.proxy.mac_addr);\n \n-\t\tif (br_fdb_test_addr_hook == NULL)\n+\t\tif (!br_fdb_test_addr_hook)\n \t\t\tbreak;\n \n \t\tif (br_fdb_test_addr_hook(dev, mesg->content.proxy.mac_addr)) {\n@@ -442,7 +442,7 @@ static int lec_atm_send(struct atm_vcc *vcc, struct sk_buff *skb)\n \t\t\tpr_debug(\"%s: entry found, responding to zeppelin\\n\",\n \t\t\t\t dev->name);\n \t\t\tskb2 = alloc_skb(sizeof(struct atmlec_msg), GFP_ATOMIC);\n-\t\t\tif (skb2 == NULL)\n+\t\t\tif (!skb2)\n \t\t\t\tbreak;\n \t\t\tskb2->len = sizeof(struct atmlec_msg);\n \t\t\tskb_copy_to_linear_data(skb2, mesg, sizeof(*mesg));\n@@ -520,7 +520,7 @@ send_to_lecd(struct lec_priv *priv, atmlec_msg_type type,\n \tmesg = (struct atmlec_msg *)skb->data;\n \tmemset(mesg, 0, sizeof(struct atmlec_msg));\n \tmesg->type = type;\n-\tif (data != NULL)\n+\tif (data)\n \t\tmesg->sizeoftlvs = data->len;\n \tif (mac_addr)\n \t\tether_addr_copy(mesg->content.normal.mac_addr, mac_addr);\n@@ -534,7 +534,7 @@ send_to_lecd(struct lec_priv *priv, atmlec_msg_type type,\n \tskb_queue_tail(&sk->sk_receive_queue, skb);\n \tsk->sk_data_ready(sk);\n \n-\tif (data != NULL) {\n+\tif (data) {\n \t\tpr_debug(\"about to send %d bytes of data\\n\", data->len);\n \t\tatm_force_charge(priv->lecd, data->truesize);\n \t\tskb_queue_tail(&sk->sk_receive_queue, data);\n@@ -663,7 +663,7 @@ static void lec_pop(struct atm_vcc *vcc, struct sk_buff *skb)\n \tstruct lec_vcc_priv *vpriv = LEC_VCC_PRIV(vcc);\n \tstruct net_device *dev = skb->dev;\n \n-\tif (vpriv == NULL) {\n+\tif (!vpriv) {\n \t\tpr_info(\"vpriv = NULL!?!?!?\\n\");\n \t\treturn;\n \t}\n@@ -1066,7 +1066,7 @@ static void __exit lane_module_cleanup(void)\n \tderegister_atm_ioctl(&lane_ioctl_ops);\n \n \tfor (i = 0; i < MAX_LEC_ITF; i++) {\n-\t\tif (dev_lec[i] != NULL) {\n+\t\tif (dev_lec[i]) {\n \t\t\tunregister_netdev(dev_lec[i]);\n \t\t\tfree_netdev(dev_lec[i]);\n \t\t\tdev_lec[i] = NULL;\n@@ -1097,11 +1097,11 @@ static int lane2_resolve(struct net_device *dev, const u8 *dst_mac, int force,\n \t\tspin_lock_irqsave(&priv->lec_arp_lock, flags);\n \t\ttable = lec_arp_find(priv, dst_mac);\n \t\tspin_unlock_irqrestore(&priv->lec_arp_lock, flags);\n-\t\tif (table == NULL)\n+\t\tif (!table)\n \t\t\treturn -1;\n \n \t\t*tlvs = kmemdup(table->tlvs, table->sizeoftlvs, GFP_ATOMIC);\n-\t\tif (*tlvs == NULL)\n+\t\tif (!*tlvs)\n \t\t\treturn -1;\n \n \t\t*sizeoftlvs = table->sizeoftlvs;\n@@ -1109,12 +1109,12 @@ static int lane2_resolve(struct net_device *dev, const u8 *dst_mac, int force,\n \t\treturn 0;\n \t}\n \n-\tif (sizeoftlvs == NULL)\n+\tif (!sizeoftlvs)\n \t\tretval = send_to_lecd(priv, l_arp_xmt, dst_mac, NULL, NULL);\n \n \telse {\n \t\tskb = alloc_skb(*sizeoftlvs, GFP_ATOMIC);\n-\t\tif (skb == NULL)\n+\t\tif (!skb)\n \t\t\treturn -1;\n \t\tskb->len = *sizeoftlvs;\n \t\tskb_copy_to_linear_data(skb, *tlvs, *sizeoftlvs);\n@@ -1143,12 +1143,12 @@ static int lane2_associate_req(struct net_device *dev, const u8 *lan_dst,\n \tkfree(priv->tlvs);\t/* NULL if there was no previous association */\n \n \tpriv->tlvs = kmemdup(tlvs, sizeoftlvs, GFP_KERNEL);\n-\tif (priv->tlvs == NULL)\n+\tif (!priv->tlvs)\n \t\treturn 0;\n \tpriv->sizeoftlvs = sizeoftlvs;\n \n \tskb = alloc_skb(sizeoftlvs, GFP_ATOMIC);\n-\tif (skb == NULL)\n+\tif (!skb)\n \t\treturn 0;\n \tskb->len = sizeoftlvs;\n \tskb_copy_to_linear_data(skb, tlvs, sizeoftlvs);\n@@ -1181,13 +1181,13 @@ static void lane2_associate_ind(struct net_device *dev, const u8 *mac_addr,\n \t\t\t\t */\n \tstruct lec_arp_table *entry = lec_arp_find(priv, mac_addr);\n \n-\tif (entry == NULL)\n+\tif (!entry)\n \t\treturn;\t\t/* should not happen */\n \n \tkfree(entry->tlvs);\n \n \tentry->tlvs = kmemdup(tlvs, sizeoftlvs, GFP_KERNEL);\n-\tif (entry->tlvs == NULL)\n+\tif (!entry->tlvs)\n \t\treturn;\n \tentry->sizeoftlvs = sizeoftlvs;\n #endif\n@@ -1854,7 +1854,7 @@ lec_arp_update(struct lec_priv *priv, const unsigned char *mac_addr,\n \n \tspin_lock_irqsave(&priv->lec_arp_lock, flags);\n \tentry = lec_arp_find(priv, mac_addr);\n-\tif (entry == NULL && targetless_le_arp)\n+\tif (!entry && targetless_le_arp)\n \t\tgoto out;\t/*\n \t\t\t\t * LANE2: ignore targetless LE_ARPs for which\n \t\t\t\t * we have no entry in the cache. 7.1.30\n@@ -1965,7 +1965,7 @@ lec_vcc_added(struct lec_priv *priv, const struct atmlec_ioc *ioc_data,\n \t\tentry->old_recv_push = old_push;\n #endif\n \t\tentry = make_entry(priv, bus_mac);\n-\t\tif (entry == NULL)\n+\t\tif (!entry)\n \t\t\tgoto out;\n \t\tdel_timer(&entry->timer);\n \t\tmemcpy(entry->atm_addr, ioc_data->atm_addr, ATM_ESA_LEN);\n@@ -1990,7 +1990,7 @@ lec_vcc_added(struct lec_priv *priv, const struct atmlec_ioc *ioc_data,\n \t\t\t ioc_data->atm_addr[16], ioc_data->atm_addr[17],\n \t\t\t ioc_data->atm_addr[18], ioc_data->atm_addr[19]);\n \t\tentry = make_entry(priv, bus_mac);\n-\t\tif (entry == NULL)\n+\t\tif (!entry)\n \t\t\tgoto out;\n \t\tmemcpy(entry->atm_addr, ioc_data->atm_addr, ATM_ESA_LEN);\n \t\teth_zero_addr(entry->mac_addr);\ndiff --git a/net/atm/mpc.c b/net/atm/mpc.c\nindex d6729d797107..ece715f8c9f7 100644\n--- a/net/atm/mpc.c\n+++ b/net/atm/mpc.c\n@@ -129,7 +129,7 @@ static struct mpoa_client *find_mpc_by_itfnum(int itf)\n \tstruct mpoa_client *mpc;\n \n \tmpc = mpcs;  /* our global linked list */\n-\twhile (mpc != NULL) {\n+\twhile (mpc) {\n \t\tif (mpc->dev_num == itf)\n \t\t\treturn mpc;\n \t\tmpc = mpc->next;\n@@ -143,7 +143,7 @@ static struct mpoa_client *find_mpc_by_vcc(struct atm_vcc *vcc)\n \tstruct mpoa_client *mpc;\n \n \tmpc = mpcs;  /* our global linked list */\n-\twhile (mpc != NULL) {\n+\twhile (mpc) {\n \t\tif (mpc->mpoad_vcc == vcc)\n \t\t\treturn mpc;\n \t\tmpc = mpc->next;\n@@ -157,7 +157,7 @@ static struct mpoa_client *find_mpc_by_lec(struct net_device *dev)\n \tstruct mpoa_client *mpc;\n \n \tmpc = mpcs;  /* our global linked list */\n-\twhile (mpc != NULL) {\n+\twhile (mpc) {\n \t\tif (mpc->dev == dev)\n \t\t\treturn mpc;\n \t\tmpc = mpc->next;\n@@ -178,7 +178,7 @@ struct atm_mpoa_qos *atm_mpoa_add_qos(__be32 dst_ip, struct atm_qos *qos)\n \tstruct atm_mpoa_qos *entry;\n \n \tentry = atm_mpoa_search_qos(dst_ip);\n-\tif (entry != NULL) {\n+\tif (entry) {\n \t\tentry->qos = *qos;\n \t\treturn entry;\n \t}\n@@ -217,7 +217,7 @@ int atm_mpoa_delete_qos(struct atm_mpoa_qos *entry)\n {\n \tstruct atm_mpoa_qos *curr;\n \n-\tif (entry == NULL)\n+\tif (!entry)\n \t\treturn 0;\n \tif (entry == qos_head) {\n \t\tqos_head = qos_head->next;\n@@ -226,7 +226,7 @@ int atm_mpoa_delete_qos(struct atm_mpoa_qos *entry)\n \t}\n \n \tcurr = qos_head;\n-\twhile (curr != NULL) {\n+\twhile (curr) {\n \t\tif (curr->next == entry) {\n \t\t\tcurr->next = entry->next;\n \t\t\tkfree(entry);\n@@ -247,7 +247,7 @@ void atm_mpoa_disp_qos(struct seq_file *m)\n \tseq_printf(m, \"QoS entries for shortcuts:\\n\");\n \tseq_printf(m, \"IP address\\n  TX:max_pcr pcr     min_pcr max_cdv max_sdu\\n  RX:max_pcr pcr     min_pcr max_cdv max_sdu\\n\");\n \n-\twhile (qos != NULL) {\n+\twhile (qos) {\n \t\tseq_printf(m, \"%pI4\\n     %-7d %-7d %-7d %-7d %-7d\\n     %-7d %-7d %-7d %-7d %-7d\\n\",\n \t\t\t   &qos->ipaddr,\n \t\t\t   qos->qos.txtp.max_pcr,\n@@ -280,7 +280,7 @@ static struct mpoa_client *alloc_mpc(void)\n \tstruct mpoa_client *mpc;\n \n \tmpc = kzalloc(sizeof(*mpc), GFP_KERNEL);\n-\tif (mpc == NULL)\n+\tif (!mpc)\n \t\treturn NULL;\n \trwlock_init(&mpc->ingress_lock);\n \trwlock_init(&mpc->egress_lock);\n@@ -381,7 +381,7 @@ static void lane2_assoc_ind(struct net_device *dev, const u8 *mac_addr,\n \tdprintk(\"(%s) received TLV(s), \", dev->name);\n \tdprintk(\"total length of all TLVs %d\\n\", sizeoftlvs);\n \tmpc = find_mpc_by_lec(dev); /* Sampo-Fix: moved here from below */\n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tpr_info(\"(%s) no mpc\\n\", dev->name);\n \t\treturn;\n \t}\n@@ -445,7 +445,7 @@ static void lane2_assoc_ind(struct net_device *dev, const u8 *mac_addr,\n \n \t\ttlvs = copy_macs(mpc, mac_addr, tlvs,\n \t\t\t\t number_of_mps_macs, mpoa_device_type);\n-\t\tif (tlvs == NULL)\n+\t\tif (!tlvs)\n \t\t\treturn;\n \t}\n \tif (end_of_tlvs - tlvs != 0)\n@@ -507,9 +507,9 @@ static int send_via_shortcut(struct sk_buff *skb, struct mpoa_client *mpc)\n \t\t mpc->dev->name, ipaddr);\n \n \tentry = mpc->in_ops->get(ipaddr, mpc);\n-\tif (entry == NULL) {\n+\tif (!entry) {\n \t\tentry = mpc->in_ops->add_entry(ipaddr, mpc);\n-\t\tif (entry != NULL)\n+\t\tif (entry)\n \t\t\tmpc->in_ops->put(entry);\n \t\treturn 1;\n \t}\n@@ -571,7 +571,7 @@ static netdev_tx_t mpc_send_packet(struct sk_buff *skb,\n \tint i = 0;\n \n \tmpc = find_mpc_by_lec(dev); /* this should NEVER fail */\n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tpr_info(\"(%s) no MPC found\\n\", dev->name);\n \t\tgoto non_ip;\n \t}\n@@ -617,16 +617,16 @@ static int atm_mpoa_vcc_attach(struct atm_vcc *vcc, void __user *arg)\n \t\treturn -EINVAL;\n \n \tmpc = find_mpc_by_itfnum(ioc_data.dev_num);\n-\tif (mpc == NULL)\n+\tif (!mpc)\n \t\treturn -EINVAL;\n \n \tif (ioc_data.type == MPC_SOCKET_INGRESS) {\n \t\tin_entry = mpc->in_ops->get(ipaddr, mpc);\n-\t\tif (in_entry == NULL ||\n+\t\tif (!in_entry ||\n \t\t    in_entry->entry_state < INGRESS_RESOLVED) {\n \t\t\tpr_info(\"(%s) did not find RESOLVED entry from ingress cache\\n\",\n \t\t\t\tmpc->dev->name);\n-\t\t\tif (in_entry != NULL)\n+\t\t\tif (in_entry)\n \t\t\t\tmpc->in_ops->put(in_entry);\n \t\t\treturn -EINVAL;\n \t\t}\n@@ -654,7 +654,7 @@ static void mpc_vcc_close(struct atm_vcc *vcc, struct net_device *dev)\n \teg_cache_entry *eg_entry;\n \n \tmpc = find_mpc_by_lec(dev);\n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tpr_info(\"(%s) close for unknown MPC\\n\", dev->name);\n \t\treturn;\n \t}\n@@ -674,7 +674,7 @@ static void mpc_vcc_close(struct atm_vcc *vcc, struct net_device *dev)\n \t\tmpc->eg_ops->put(eg_entry);\n \t}\n \n-\tif (in_entry == NULL && eg_entry == NULL)\n+\tif (!in_entry && !eg_entry)\n \t\tdprintk(\"(%s) unused vcc closed\\n\", dev->name);\n }\n \n@@ -688,7 +688,7 @@ static void mpc_push(struct atm_vcc *vcc, struct sk_buff *skb)\n \tchar *tmp;\n \n \tddprintk(\"(%s)\\n\", dev->name);\n-\tif (skb == NULL) {\n+\tif (!skb) {\n \t\tdprintk(\"(%s) null skb, closing VCC\\n\", dev->name);\n \t\tmpc_vcc_close(vcc, dev);\n \t\treturn;\n@@ -710,7 +710,7 @@ static void mpc_push(struct atm_vcc *vcc, struct sk_buff *skb)\n \tatm_return(vcc, skb->truesize);\n \n \tmpc = find_mpc_by_lec(dev);\n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tpr_info(\"(%s) unknown MPC\\n\", dev->name);\n \t\treturn;\n \t}\n@@ -735,7 +735,7 @@ static void mpc_push(struct atm_vcc *vcc, struct sk_buff *skb)\n \ttag = *(__be32 *)tmp;\n \n \teg = mpc->eg_ops->get_by_tag(tag, mpc);\n-\tif (eg == NULL) {\n+\tif (!eg) {\n \t\tpr_info(\"mpoa: (%s) Didn't find egress cache entry, tag = %u\\n\",\n \t\t\tdev->name, tag);\n \t\tpurge_egress_shortcut(vcc, NULL);\n@@ -747,7 +747,7 @@ static void mpc_push(struct atm_vcc *vcc, struct sk_buff *skb)\n \t * See if ingress MPC is using shortcut we opened as a return channel.\n \t * This means we have a bi-directional vcc opened by us.\n \t */\n-\tif (eg->shortcut == NULL) {\n+\tif (!eg->shortcut) {\n \t\teg->shortcut = vcc;\n \t\tpr_info(\"(%s) egress SVC in use\\n\", dev->name);\n \t}\n@@ -757,7 +757,7 @@ static void mpc_push(struct atm_vcc *vcc, struct sk_buff *skb)\n \tnew_skb = skb_realloc_headroom(skb, eg->ctrl_info.DH_length);\n \t\t\t\t\t/* LLC/SNAP is shorter than MAC header :( */\n \tdev_kfree_skb_any(skb);\n-\tif (new_skb == NULL) {\n+\tif (!new_skb) {\n \t\tmpc->eg_ops->put(eg);\n \t\treturn;\n \t}\n@@ -794,7 +794,7 @@ static int atm_mpoa_mpoad_attach(struct atm_vcc *vcc, int arg)\n \tstruct lec_priv *priv;\n \tint err;\n \n-\tif (mpcs == NULL) {\n+\tif (!mpcs) {\n \t\tinit_timer(&mpc_timer);\n \t\tmpc_timer_refresh();\n \n@@ -807,10 +807,10 @@ static int atm_mpoa_mpoad_attach(struct atm_vcc *vcc, int arg)\n \t}\n \n \tmpc = find_mpc_by_itfnum(arg);\n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tdprintk(\"allocating new mpc for itf %d\\n\", arg);\n \t\tmpc = alloc_mpc();\n-\t\tif (mpc == NULL)\n+\t\tif (!mpc)\n \t\t\treturn -ENOMEM;\n \t\tmpc->dev_num = arg;\n \t\tmpc->dev = find_lec_by_itfnum(arg);\n@@ -869,7 +869,7 @@ static void mpoad_close(struct atm_vcc *vcc)\n \tstruct sk_buff *skb;\n \n \tmpc = find_mpc_by_vcc(vcc);\n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tpr_info(\"did not find MPC\\n\");\n \t\treturn;\n \t}\n@@ -909,7 +909,7 @@ static int msg_from_mpoad(struct atm_vcc *vcc, struct sk_buff *skb)\n \tstruct k_message *mesg = (struct k_message *)skb->data;\n \tWARN_ON(refcount_sub_and_test(skb->truesize, &sk_atm(vcc)->sk_wmem_alloc));\n \n-\tif (mpc == NULL) {\n+\tif (!mpc) {\n \t\tpr_info(\"no mpc found\\n\");\n \t\treturn 0;\n \t}\n@@ -974,13 +974,13 @@ int msg_to_mpoad(struct k_message *mesg, struct mpoa_client *mpc)\n \tstruct sk_buff *skb;\n \tstruct sock *sk;\n \n-\tif (mpc == NULL || !mpc->mpoad_vcc) {\n+\tif (!mpc || !mpc->mpoad_vcc) {\n \t\tpr_info(\"mesg %d to a non-existent mpoad\\n\", mesg->type);\n \t\treturn -ENXIO;\n \t}\n \n \tskb = alloc_skb(sizeof(struct k_message), GFP_ATOMIC);\n-\tif (skb == NULL)\n+\tif (!skb)\n \t\treturn -ENOMEM;\n \tskb_put(skb, sizeof(struct k_message));\n \tskb_copy_to_linear_data(skb, mesg, sizeof(*mesg));\n@@ -1013,10 +1013,10 @@ static int mpoa_event_listener(struct notifier_block *mpoa_notifier,\n \t\t\tbreak;\n \t\tpriv->lane2_ops->associate_indicator = lane2_assoc_ind;\n \t\tmpc = find_mpc_by_itfnum(priv->itfnum);\n-\t\tif (mpc == NULL) {\n+\t\tif (!mpc) {\n \t\t\tdprintk(\"allocating new mpc for %s\\n\", dev->name);\n \t\t\tmpc = alloc_mpc();\n-\t\t\tif (mpc == NULL) {\n+\t\t\tif (!mpc) {\n \t\t\t\tpr_info(\"no new mpc\");\n \t\t\t\tbreak;\n \t\t\t}\n@@ -1029,7 +1029,7 @@ static int mpoa_event_listener(struct notifier_block *mpoa_notifier,\n \tcase NETDEV_UNREGISTER:\n \t\t/* the lec device was deallocated */\n \t\tmpc = find_mpc_by_lec(dev);\n-\t\tif (mpc == NULL)\n+\t\tif (!mpc)\n \t\t\tbreak;\n \t\tdprintk(\"device (%s) was deallocated\\n\", dev->name);\n \t\tstop_mpc(mpc);\n@@ -1039,9 +1039,9 @@ static int mpoa_event_listener(struct notifier_block *mpoa_notifier,\n \tcase NETDEV_UP:\n \t\t/* the dev was ifconfig'ed up */\n \t\tmpc = find_mpc_by_lec(dev);\n-\t\tif (mpc == NULL)\n+\t\tif (!mpc)\n \t\t\tbreak;\n-\t\tif (mpc->mpoad_vcc != NULL)\n+\t\tif (mpc->mpoad_vcc)\n \t\t\tstart_mpc(mpc, dev);\n \t\tbreak;\n \tcase NETDEV_DOWN:\n@@ -1050,9 +1050,9 @@ static int mpoa_event_listener(struct notifier_block *mpoa_notifier,\n \t\t * upper layer stops\n \t\t */\n \t\tmpc = find_mpc_by_lec(dev);\n-\t\tif (mpc == NULL)\n+\t\tif (!mpc)\n \t\t\tbreak;\n-\t\tif (mpc->mpoad_vcc != NULL)\n+\t\tif (mpc->mpoad_vcc)\n \t\t\tstop_mpc(mpc);\n \t\tbreak;\n \tcase NETDEV_REBOOT:\n@@ -1080,7 +1080,7 @@ static void MPOA_trigger_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n \tin_cache_entry *entry;\n \n \tentry = mpc->in_ops->get(dst_ip, mpc);\n-\tif (entry == NULL) {\n+\tif (!entry) {\n \t\tentry = mpc->in_ops->add_entry(dst_ip, mpc);\n \t\tentry->entry_state = INGRESS_RESOLVING;\n \t\tmsg->type = SND_MPOA_RES_RQST;\n@@ -1134,7 +1134,7 @@ static void check_qos_and_open_shortcut(struct k_message *msg,\n \t\t\treturn;\n \t\t}\n \t}\n-\tif (eg_entry != NULL)\n+\tif (eg_entry)\n \t\tclient->eg_ops->put(eg_entry);\n \n \t/* No luck in the egress cache we must open an ingress SVC */\n@@ -1158,7 +1158,7 @@ static void MPOA_res_reply_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n \t\tmpc->dev->name, &dst_ip);\n \tddprintk(\"(%s) entry = %p\",\n \t\t mpc->dev->name, entry);\n-\tif (entry == NULL) {\n+\tif (!entry) {\n \t\tpr_info(\"(%s) ARGH, received res. reply for an entry that doesn't exist.\\n\",\n \t\t\tmpc->dev->name);\n \t\treturn;\n@@ -1178,13 +1178,13 @@ static void MPOA_res_reply_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n \tddprintk_cont(\"entry->shortcut = %p\\n\", entry->shortcut);\n \n \tif (entry->entry_state == INGRESS_RESOLVING &&\n-\t    entry->shortcut != NULL) {\n+\t    entry->shortcut) {\n \t\tentry->entry_state = INGRESS_RESOLVED;\n \t\tmpc->in_ops->put(entry);\n \t\treturn; /* Shortcut already open... */\n \t}\n \n-\tif (entry->shortcut != NULL) {\n+\tif (entry->shortcut) {\n \t\tpr_info(\"(%s) entry->shortcut != NULL, impossible!\\n\",\n \t\t\tmpc->dev->name);\n \t\tmpc->in_ops->put(entry);\n@@ -1205,7 +1205,7 @@ static void ingress_purge_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n \t__be32 mask = msg->ip_mask;\n \tin_cache_entry *entry = mpc->in_ops->get_with_mask(dst_ip, mpc, mask);\n \n-\tif (entry == NULL) {\n+\tif (!entry) {\n \t\tpr_info(\"(%s) purge for a non-existing entry, ip = %pI4\\n\",\n \t\t\tmpc->dev->name, &dst_ip);\n \t\treturn;\n@@ -1219,7 +1219,7 @@ static void ingress_purge_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n \t\twrite_unlock_bh(&mpc->ingress_lock);\n \t\tmpc->in_ops->put(entry);\n \t\tentry = mpc->in_ops->get_with_mask(dst_ip, mpc, mask);\n-\t} while (entry != NULL);\n+\t} while (entry);\n }\n \n static void egress_purge_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n@@ -1227,7 +1227,7 @@ static void egress_purge_rcvd(struct k_message *msg, struct mpoa_client *mpc)\n \t__be32 cache_id = msg->content.eg_info.cache_id;\n \teg_cache_entry *entry = mpc->eg_ops->get_by_cache_id(cache_id, mpc);\n \n-\tif (entry == NULL) {\n+\tif (!entry) {\n \t\tdprintk(\"(%s) purge for a non-existing entry\\n\",\n \t\t\tmpc->dev->name);\n \t\treturn;\n@@ -1247,13 +1247,13 @@ static void purge_egress_shortcut(struct atm_vcc *vcc, eg_cache_entry *entry)\n \tstruct sk_buff *skb;\n \n \tdprintk(\"entering\\n\");\n-\tif (vcc == NULL) {\n+\tif (!vcc) {\n \t\tpr_info(\"vcc == NULL\\n\");\n \t\treturn;\n \t}\n \n \tskb = alloc_skb(sizeof(struct k_message), GFP_ATOMIC);\n-\tif (skb == NULL) {\n+\tif (!skb) {\n \t\tpr_info(\"out of memory\\n\");\n \t\treturn;\n \t}\n@@ -1262,7 +1262,7 @@ static void purge_egress_shortcut(struct atm_vcc *vcc, eg_cache_entry *entry)\n \tmemset(skb->data, 0, sizeof(struct k_message));\n \tpurge_msg = (struct k_message *)skb->data;\n \tpurge_msg->type = DATA_PLANE_PURGE;\n-\tif (entry != NULL)\n+\tif (entry)\n \t\tpurge_msg->content.eg_info = entry->ctrl_info;\n \n \tatm_force_charge(vcc, skb->truesize);\n@@ -1291,7 +1291,7 @@ static void mps_death(struct k_message *msg, struct mpoa_client *mpc)\n \t/* FIXME: This knows too much of the cache structure */\n \tread_lock_irq(&mpc->egress_lock);\n \tentry = mpc->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tpurge_egress_shortcut(entry->shortcut, entry);\n \t\tentry = entry->next;\n \t}\n@@ -1310,7 +1310,7 @@ static void MPOA_cache_impos_rcvd(struct k_message *msg,\n \tholding_time = msg->content.eg_info.holding_time;\n \tdprintk(\"(%s) entry = %p, holding_time = %u\\n\",\n \t\tmpc->dev->name, entry, holding_time);\n-\tif (entry == NULL && holding_time) {\n+\tif (!entry && holding_time) {\n \t\tentry = mpc->eg_ops->add_entry(msg, mpc);\n \t\tmpc->eg_ops->put(entry);\n \t\treturn;\n@@ -1372,7 +1372,7 @@ static void set_mps_mac_addr_rcvd(struct k_message *msg,\n \t\tkfree(client->mps_macs);\n \tclient->number_of_mps_macs = 0;\n \tclient->mps_macs = kmemdup(msg->MPS_ctrl, ETH_ALEN, GFP_KERNEL);\n-\tif (client->mps_macs == NULL) {\n+\tif (!client->mps_macs) {\n \t\tpr_info(\"out of memory\\n\");\n \t\treturn;\n \t}\n@@ -1392,7 +1392,7 @@ static void clean_up(struct k_message *msg, struct mpoa_client *mpc, int action)\n \t/* FIXME: This knows too much of the cache structure */\n \tread_lock_irq(&mpc->egress_lock);\n \tentry = mpc->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tmsg->content.eg_info = entry->ctrl_info;\n \t\tdprintk(\"cache_id %u\\n\", entry->ctrl_info.cache_id);\n \t\tmsg_to_mpoad(msg, mpc);\n@@ -1418,7 +1418,7 @@ static void mpc_cache_check(unsigned long checking_time)\n \tstatic unsigned long previous_resolving_check_time;\n \tstatic unsigned long previous_refresh_time;\n \n-\twhile (mpc != NULL) {\n+\twhile (mpc) {\n \t\tmpc->in_ops->clear_count(mpc);\n \t\tmpc->eg_ops->clear_expired(mpc);\n \t\tif (checking_time - previous_resolving_check_time >\n@@ -1494,12 +1494,12 @@ static void __exit atm_mpoa_cleanup(void)\n \n \tmpc = mpcs;\n \tmpcs = NULL;\n-\twhile (mpc != NULL) {\n+\twhile (mpc) {\n \t\ttmp = mpc->next;\n-\t\tif (mpc->dev != NULL) {\n+\t\tif (mpc->dev) {\n \t\t\tstop_mpc(mpc);\n \t\t\tpriv = netdev_priv(mpc->dev);\n-\t\t\tif (priv->lane2_ops != NULL)\n+\t\t\tif (priv->lane2_ops)\n \t\t\t\tpriv->lane2_ops->associate_indicator = NULL;\n \t\t}\n \t\tddprintk(\"about to clear caches\\n\");\n@@ -1516,7 +1516,7 @@ static void __exit atm_mpoa_cleanup(void)\n \n \tqos = qos_head;\n \tqos_head = NULL;\n-\twhile (qos != NULL) {\n+\twhile (qos) {\n \t\tnextqos = qos->next;\n \t\tdprintk(\"freeing qos entry %p\\n\", qos);\n \t\tkfree(qos);\ndiff --git a/net/atm/mpoa_caches.c b/net/atm/mpoa_caches.c\nindex 23f36e5a20ee..c147fe916446 100644\n--- a/net/atm/mpoa_caches.c\n+++ b/net/atm/mpoa_caches.c\n@@ -38,7 +38,7 @@ static in_cache_entry *in_cache_get(__be32 dst_ip,\n \n \tread_lock_bh(&client->ingress_lock);\n \tentry = client->in_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->ctrl_info.in_dst_ip == dst_ip) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_bh(&client->ingress_lock);\n@@ -59,7 +59,7 @@ static in_cache_entry *in_cache_get_with_mask(__be32 dst_ip,\n \n \tread_lock_bh(&client->ingress_lock);\n \tentry = client->in_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif ((entry->ctrl_info.in_dst_ip & mask) == (dst_ip & mask)) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_bh(&client->ingress_lock);\n@@ -80,7 +80,7 @@ static in_cache_entry *in_cache_get_by_vcc(struct atm_vcc *vcc,\n \n \tread_lock_bh(&client->ingress_lock);\n \tentry = client->in_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->shortcut == vcc) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_bh(&client->ingress_lock);\n@@ -108,7 +108,7 @@ static in_cache_entry *in_cache_add_entry(__be32 dst_ip,\n \twrite_lock_bh(&client->ingress_lock);\n \tentry->next = client->in_cache;\n \tentry->prev = NULL;\n-\tif (client->in_cache != NULL)\n+\tif (client->in_cache)\n \t\tclient->in_cache->prev = entry;\n \tclient->in_cache = entry;\n \n@@ -133,7 +133,7 @@ static int cache_hit(in_cache_entry *entry, struct mpoa_client *mpc)\n \tstruct k_message msg;\n \n \tentry->count++;\n-\tif (entry->entry_state == INGRESS_RESOLVED && entry->shortcut != NULL)\n+\tif (entry->entry_state == INGRESS_RESOLVED && entry->shortcut)\n \t\treturn OPEN;\n \n \tif (entry->entry_state == INGRESS_REFRESHING) {\n@@ -142,18 +142,18 @@ static int cache_hit(in_cache_entry *entry, struct mpoa_client *mpc)\n \t\t\tmsg.content.in_info = entry->ctrl_info;\n \t\t\tmemcpy(msg.MPS_ctrl, mpc->mps_ctrl_addr, ATM_ESA_LEN);\n \t\t\tqos = atm_mpoa_search_qos(entry->ctrl_info.in_dst_ip);\n-\t\t\tif (qos != NULL)\n+\t\t\tif (qos)\n \t\t\t\tmsg.qos = qos->qos;\n \t\t\tmsg_to_mpoad(&msg, mpc);\n \t\t\tdo_gettimeofday(&(entry->reply_wait));\n \t\t\tentry->entry_state = INGRESS_RESOLVING;\n \t\t}\n-\t\tif (entry->shortcut != NULL)\n+\t\tif (entry->shortcut)\n \t\t\treturn OPEN;\n \t\treturn CLOSED;\n \t}\n \n-\tif (entry->entry_state == INGRESS_RESOLVING && entry->shortcut != NULL)\n+\tif (entry->entry_state == INGRESS_RESOLVING && entry->shortcut)\n \t\treturn OPEN;\n \n \tif (entry->count > mpc->parameters.mpc_p1 &&\n@@ -165,7 +165,7 @@ static int cache_hit(in_cache_entry *entry, struct mpoa_client *mpc)\n \t\tmemcpy(msg.MPS_ctrl, mpc->mps_ctrl_addr, ATM_ESA_LEN);\n \t\tmsg.content.in_info = entry->ctrl_info;\n \t\tqos = atm_mpoa_search_qos(entry->ctrl_info.in_dst_ip);\n-\t\tif (qos != NULL)\n+\t\tif (qos)\n \t\t\tmsg.qos = qos->qos;\n \t\tmsg_to_mpoad(&msg, mpc);\n \t\tdo_gettimeofday(&(entry->reply_wait));\n@@ -195,23 +195,24 @@ static void in_cache_remove_entry(in_cache_entry *entry,\n \tdprintk(\"removing an ingress entry, ip = %pI4\\n\",\n \t\t&entry->ctrl_info.in_dst_ip);\n \n-\tif (entry->prev != NULL)\n+\tif (entry->prev)\n \t\tentry->prev->next = entry->next;\n \telse\n \t\tclient->in_cache = entry->next;\n-\tif (entry->next != NULL)\n+\tif (entry->next)\n \t\tentry->next->prev = entry->prev;\n \tclient->in_ops->put(entry);\n-\tif (client->in_cache == NULL && client->eg_cache == NULL) {\n+\tif (!client->in_cache && !client->eg_cache) {\n \t\tmsg.type = STOP_KEEP_ALIVE_SM;\n \t\tmsg_to_mpoad(&msg, client);\n \t}\n \n \t/* Check if the egress side still uses this VCC */\n-\tif (vcc != NULL) {\n+\tif (vcc) {\n \t\teg_cache_entry *eg_entry = client->eg_ops->get_by_vcc(vcc,\n \t\t\t\t\t\t\t\t      client);\n-\t\tif (eg_entry != NULL) {\n+\n+\t\tif (eg_entry) {\n \t\t\tclient->eg_ops->put(eg_entry);\n \t\t\treturn;\n \t\t}\n@@ -230,7 +231,7 @@ static void clear_count_and_expired(struct mpoa_client *client)\n \n \twrite_lock_bh(&client->ingress_lock);\n \tentry = client->in_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tentry->count = 0;\n \t\tnext_entry = entry->next;\n \t\tif ((now.tv_sec - entry->tv.tv_sec)\n@@ -257,7 +258,7 @@ static void check_resolving_entries(struct mpoa_client *client)\n \n \tread_lock_bh(&client->ingress_lock);\n \tentry = client->in_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->entry_state == INGRESS_RESOLVING) {\n \t\t\tif ((now.tv_sec - entry->hold_down.tv_sec) <\n \t\t\t    client->parameters.mpc_p6) {\n@@ -283,7 +284,7 @@ static void check_resolving_entries(struct mpoa_client *client)\n \t\t\t\tmemcpy(msg.MPS_ctrl, client->mps_ctrl_addr, ATM_ESA_LEN);\n \t\t\t\tmsg.content.in_info = entry->ctrl_info;\n \t\t\t\tqos = atm_mpoa_search_qos(entry->ctrl_info.in_dst_ip);\n-\t\t\t\tif (qos != NULL)\n+\t\t\t\tif (qos)\n \t\t\t\t\tmsg.qos = qos->qos;\n \t\t\t\tmsg_to_mpoad(&msg, client);\n \t\t\t\tdo_gettimeofday(&(entry->reply_wait));\n@@ -304,7 +305,7 @@ static void refresh_entries(struct mpoa_client *client)\n \tdo_gettimeofday(&now);\n \n \tread_lock_bh(&client->ingress_lock);\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->entry_state == INGRESS_RESOLVED) {\n \t\t\tif (!(entry->refresh_time))\n \t\t\t\tentry->refresh_time = (2 * (entry->ctrl_info.holding_time))/3;\n@@ -323,7 +324,7 @@ static void refresh_entries(struct mpoa_client *client)\n static void in_destroy_cache(struct mpoa_client *mpc)\n {\n \twrite_lock_irq(&mpc->ingress_lock);\n-\twhile (mpc->in_cache != NULL)\n+\twhile (mpc->in_cache)\n \t\tmpc->in_ops->remove_entry(mpc->in_cache, mpc);\n \twrite_unlock_irq(&mpc->ingress_lock);\n }\n@@ -335,7 +336,7 @@ static eg_cache_entry *eg_cache_get_by_cache_id(__be32 cache_id,\n \n \tread_lock_irq(&mpc->egress_lock);\n \tentry = mpc->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->ctrl_info.cache_id == cache_id) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_irq(&mpc->egress_lock);\n@@ -356,7 +357,7 @@ static eg_cache_entry *eg_cache_get_by_tag(__be32 tag, struct mpoa_client *mpc)\n \n \tread_lock_irqsave(&mpc->egress_lock, flags);\n \tentry = mpc->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->ctrl_info.tag == tag) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_irqrestore(&mpc->egress_lock, flags);\n@@ -378,7 +379,7 @@ static eg_cache_entry *eg_cache_get_by_vcc(struct atm_vcc *vcc,\n \n \tread_lock_irqsave(&mpc->egress_lock, flags);\n \tentry = mpc->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->shortcut == vcc) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_irqrestore(&mpc->egress_lock, flags);\n@@ -398,7 +399,7 @@ static eg_cache_entry *eg_cache_get_by_src_ip(__be32 ipaddr,\n \n \tread_lock_irq(&mpc->egress_lock);\n \tentry = mpc->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tif (entry->latest_ip_addr == ipaddr) {\n \t\t\trefcount_inc(&entry->use);\n \t\t\tread_unlock_irq(&mpc->egress_lock);\n@@ -430,22 +431,22 @@ static void eg_cache_remove_entry(eg_cache_entry *entry,\n \n \tvcc = entry->shortcut;\n \tdprintk(\"removing an egress entry.\\n\");\n-\tif (entry->prev != NULL)\n+\tif (entry->prev)\n \t\tentry->prev->next = entry->next;\n \telse\n \t\tclient->eg_cache = entry->next;\n-\tif (entry->next != NULL)\n+\tif (entry->next)\n \t\tentry->next->prev = entry->prev;\n \tclient->eg_ops->put(entry);\n-\tif (client->in_cache == NULL && client->eg_cache == NULL) {\n+\tif (!client->in_cache && !client->eg_cache) {\n \t\tmsg.type = STOP_KEEP_ALIVE_SM;\n \t\tmsg_to_mpoad(&msg, client);\n \t}\n \n \t/* Check if the ingress side still uses this VCC */\n-\tif (vcc != NULL) {\n+\tif (vcc) {\n \t\tin_cache_entry *in_entry = client->in_ops->get_by_vcc(vcc, client);\n-\t\tif (in_entry != NULL) {\n+\t\tif (in_entry) {\n \t\t\tclient->in_ops->put(in_entry);\n \t\t\treturn;\n \t\t}\n@@ -469,7 +470,7 @@ static eg_cache_entry *eg_cache_add_entry(struct k_message *msg,\n \twrite_lock_irq(&client->egress_lock);\n \tentry->next = client->eg_cache;\n \tentry->prev = NULL;\n-\tif (client->eg_cache != NULL)\n+\tif (client->eg_cache)\n \t\tclient->eg_cache->prev = entry;\n \tclient->eg_cache = entry;\n \n@@ -505,7 +506,7 @@ static void clear_expired(struct mpoa_client *client)\n \n \twrite_lock_irq(&client->egress_lock);\n \tentry = client->eg_cache;\n-\twhile (entry != NULL) {\n+\twhile (entry) {\n \t\tnext_entry = entry->next;\n \t\tif ((now.tv_sec - entry->tv.tv_sec)\n \t\t   > entry->ctrl_info.holding_time) {\n@@ -524,7 +525,7 @@ static void clear_expired(struct mpoa_client *client)\n static void eg_destroy_cache(struct mpoa_client *mpc)\n {\n \twrite_lock_irq(&mpc->egress_lock);\n-\twhile (mpc->eg_cache != NULL)\n+\twhile (mpc->eg_cache)\n \t\tmpc->eg_ops->remove_entry(mpc->eg_cache, mpc);\n \twrite_unlock_irq(&mpc->egress_lock);\n }\ndiff --git a/net/atm/pppoatm.c b/net/atm/pppoatm.c\nindex 21d9d341a619..890eb377e2dd 100644\n--- a/net/atm/pppoatm.c\n+++ b/net/atm/pppoatm.c\n@@ -183,7 +183,7 @@ static void pppoatm_push(struct atm_vcc *atmvcc, struct sk_buff *skb)\n {\n \tstruct pppoatm_vcc *pvcc = atmvcc_to_pvcc(atmvcc);\n \tpr_debug(\"\\n\");\n-\tif (skb == NULL) {\t\t\t/* VCC was closed */\n+\tif (!skb) {\t\t\t/* VCC was closed */\n \t\tstruct module *module;\n \n \t\tpr_debug(\"removing ATMPPP VCC %p\\n\", pvcc);\n@@ -202,7 +202,7 @@ static void pppoatm_push(struct atm_vcc *atmvcc, struct sk_buff *skb)\n \t\tskb_pull(skb, LLC_LEN);\n \t\tbreak;\n \tcase e_autodetect:\n-\t\tif (pvcc->chan.ppp == NULL) {\t/* Not bound yet! */\n+\t\tif (!pvcc->chan.ppp) {\t/* Not bound yet! */\n \t\t\tkfree_skb(skb);\n \t\t\treturn;\n \t\t}\n@@ -324,14 +324,13 @@ static int pppoatm_send(struct ppp_channel *chan, struct sk_buff *skb)\n \t\tif (skb_headroom(skb) < LLC_LEN) {\n \t\t\tstruct sk_buff *n;\n \t\t\tn = skb_realloc_headroom(skb, LLC_LEN);\n-\t\t\tif (n != NULL &&\n-\t\t\t    !pppoatm_may_send(pvcc, n->truesize)) {\n+\t\t\tif (n && !pppoatm_may_send(pvcc, n->truesize)) {\n \t\t\t\tkfree_skb(n);\n \t\t\t\tgoto nospace;\n \t\t\t}\n \t\t\tconsume_skb(skb);\n \t\t\tskb = n;\n-\t\t\tif (skb == NULL) {\n+\t\t\tif (!skb) {\n \t\t\t\tbh_unlock_sock(sk_atm(vcc));\n \t\t\t\treturn DROP_PACKET;\n \t\t\t}\n@@ -406,7 +405,7 @@ static int pppoatm_assign_vcc(struct atm_vcc *atmvcc, void __user *arg)\n \t    be.encaps != PPPOATM_ENCAPS_VC && be.encaps != PPPOATM_ENCAPS_LLC)\n \t\treturn -EINVAL;\n \tpvcc = kzalloc(sizeof(*pvcc), GFP_KERNEL);\n-\tif (pvcc == NULL)\n+\tif (!pvcc)\n \t\treturn -ENOMEM;\n \tpvcc->atmvcc = atmvcc;\n \ndiff --git a/net/atm/proc.c b/net/atm/proc.c\nindex 4caca2a90ec4..aa230079cf8a 100644\n--- a/net/atm/proc.c\n+++ b/net/atm/proc.c\n@@ -118,7 +118,7 @@ static int __vcc_seq_open(struct inode *inode, struct file *file,\n \tstruct vcc_state *state;\n \n \tstate = __seq_open_private(file, ops, sizeof(*state));\n-\tif (state == NULL)\n+\tif (!state)\n \t\treturn -ENOMEM;\n \n \tstate->family = family;\n",
    "prefixes": [
        "3/3"
    ]
}