All of lore.kernel.org
 help / color / mirror / Atom feed
From: Xiao Ni <xni@redhat.com>
To: jes.sorensen@gmail.com
Cc: ncroxon@redhat.com, linux-raid@vger.kernel.org,
	mariusz.tkaczyk@linux.intel.com
Subject: [PATCH 1/1] Fix some building errors
Date: Fri, 23 Apr 2021 14:01:30 +0800	[thread overview]
Message-ID: <1619157690-5443-1-git-send-email-xni@redhat.com> (raw)

There are some building errors if treating warning as errors.
Fix them in this patch.

Signed-off-by: Xiao Ni <xni@redhat.com>
---
 super-intel.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/super-intel.c b/super-intel.c
index 876e077..08bf2a3 100644
--- a/super-intel.c
+++ b/super-intel.c
@@ -3192,7 +3192,7 @@ static int imsm_create_metadata_checkpoint_update(
 	}
 	(*u)->type = update_general_migration_checkpoint;
 	(*u)->curr_migr_unit = current_migr_unit(super->migr_rec);
-	dprintf("prepared for %llu\n", (*u)->curr_migr_unit);
+	dprintf("prepared for %llu\n", (unsigned long long)(*u)->curr_migr_unit);
 
 	return update_memory_size;
 }
@@ -11127,7 +11127,7 @@ int recover_backup_imsm(struct supertype *st, struct mdinfo *info)
 			skipped_disks++;
 			continue;
 		}
-		if (read(dl_disk->fd, buf, unit_len) != unit_len) {
+		if (read(dl_disk->fd, buf, unit_len) != (ssize_t)unit_len) {
 			pr_err("Cannot read copy area block: %s\n",
 			       strerror(errno));
 			skipped_disks++;
@@ -11139,7 +11139,7 @@ int recover_backup_imsm(struct supertype *st, struct mdinfo *info)
 			skipped_disks++;
 			continue;
 		}
-		if (write(dl_disk->fd, buf, unit_len) != unit_len) {
+		if (write(dl_disk->fd, buf, unit_len) != (ssize_t)unit_len) {
 			pr_err("Cannot restore block: %s\n",
 			       strerror(errno));
 			skipped_disks++;
-- 
2.7.5


             reply	other threads:[~2021-04-23  6:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-23  6:01 Xiao Ni [this message]
2021-05-06 20:47 ` [PATCH 1/1] Fix some building errors Jes Sorensen

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=1619157690-5443-1-git-send-email-xni@redhat.com \
    --to=xni@redhat.com \
    --cc=jes.sorensen@gmail.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=mariusz.tkaczyk@linux.intel.com \
    --cc=ncroxon@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.