Skip to content

Commit

Permalink
nfc: pn544: drop unneeded memory allocation fail messages
Browse files Browse the repository at this point in the history
nfc_mei_phy_alloc() already prints an error message on memory allocation
failure.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Krzysztof Kozlowski authored and David S. Miller committed Sep 13, 2021
1 parent aed4146 commit 64758c6
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/nfc/pn544/mei.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,8 @@ static int pn544_mei_probe(struct mei_cl_device *cldev,
int r;

phy = nfc_mei_phy_alloc(cldev);
if (!phy) {
pr_err("Cannot allocate memory for pn544 mei phy.\n");
if (!phy)
return -ENOMEM;
}

r = pn544_hci_probe(phy, &mei_phy_ops, LLC_NOP_NAME,
MEI_NFC_HEADER_SIZE, 0, MEI_NFC_MAX_HCI_PAYLOAD,
Expand Down

0 comments on commit 64758c6

Please sign in to comment.