From: Dan Carpenter <dan.carpenter@oracle.com>
To: teg@jklm.no
Cc: linux-fsdevel@vger.kernel.org
Subject: re: efi: split efisubsystem from efivars
Date: Wed, 15 Jun 2016 16:05:24 +0300 [thread overview]
Message-ID: <20160615130524.GA15133@mwanda> (raw)
Hello Tom Gundersen,
The patch a9499fa7cd3f: "efi: split efisubsystem from efivars" from
Feb 8, 2013, leads to the following static checker warning:
fs/super.c:1094 mount_single()
error: passing non negative 1 to ERR_PTR
drivers/firmware/efi/efivars.c
638 static int efivar_update_sysfs_entry(efi_char16_t *name, efi_guid_t vendor,
639 unsigned long name_size, void *data)
640 {
641 struct efivar_entry *entry = data;
642
643 if (efivar_entry_find(name, vendor, &efivar_sysfs_list, false))
644 return 0;
645
646 memcpy(entry->var.VariableName, name, name_size);
647 memcpy(&(entry->var.VendorGuid), &vendor, sizeof(efi_guid_t));
648
649 return 1;
The comments imply that this should return 0 on success and negative
error codes on failure.
650 }
651
The function is called from efivar_init() as a pointer.
663 err = efivar_init(efivar_update_sysfs_entry, entry,
664 false, &efivar_sysfs_list);
The comments on efivar_init() say it should return zero on success or a
negative error code.
regards,
dan carpenter
reply other threads:[~2016-06-15 13:05 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160615130524.GA15133@mwanda \
--to=dan.carpenter@oracle.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=teg@jklm.no \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).