]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
nvme: Don't clear nvme blk device's priv space
authorBin Meng <bmeng.cn@gmail.com>
Tue, 22 Jun 2021 13:16:21 +0000 (21:16 +0800)
committerBin Meng <bmeng.cn@gmail.com>
Wed, 23 Jun 2021 09:21:14 +0000 (17:21 +0800)
A udevice's priv space is cleared in alloc_priv() in the DM core.
Don't do it again in its probe() routine.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
drivers/nvme/nvme.c

index d4b2860d67f9306556c8917cb11b1227c830bd1a..f6465ea7f482a7b7ffe933152cc1374514c54711 100644 (file)
@@ -705,7 +705,6 @@ static int nvme_blk_probe(struct udevice *udev)
        if (!id)
                return -ENOMEM;
 
-       memset(ns, 0, sizeof(*ns));
        ns->dev = ndev;
        /* extract the namespace id from the block device name */
        ns->ns_id = trailing_strtol(udev->name);