]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/blobdiff - sound/soc/codecs/tlv320aic3x.c
Merge remote-tracking branches 'asoc/topic/tlv320aic3x', 'asoc/topic/width', 'asoc...
[mirror_ubuntu-eoan-kernel.git] / sound / soc / codecs / tlv320aic3x.c
index 00b127fe2b771bf8513aa340dd2950704efe0790..64f179ee98345f841319599c255188e14fc37767 100644 (file)
@@ -1478,10 +1478,8 @@ static int aic3x_i2c_probe(struct i2c_client *i2c,
        u32 value;
 
        aic3x = devm_kzalloc(&i2c->dev, sizeof(struct aic3x_priv), GFP_KERNEL);
-       if (aic3x == NULL) {
-               dev_err(&i2c->dev, "failed to create private data\n");
+       if (!aic3x)
                return -ENOMEM;
-       }
 
        aic3x->regmap = devm_regmap_init_i2c(i2c, &aic3x_regmap);
        if (IS_ERR(aic3x->regmap)) {
@@ -1499,10 +1497,8 @@ static int aic3x_i2c_probe(struct i2c_client *i2c,
        } else if (np) {
                ai3x_setup = devm_kzalloc(&i2c->dev, sizeof(*ai3x_setup),
                                                                GFP_KERNEL);
-               if (ai3x_setup == NULL) {
-                       dev_err(&i2c->dev, "failed to create private data\n");
+               if (!ai3x_setup)
                        return -ENOMEM;
-               }
 
                ret = of_get_named_gpio(np, "gpio-reset", 0);
                if (ret >= 0)