From: Andrei Pelinescu-Onciul <andrei@iptel.org>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: "David S. Miller" <davem@davemloft.net>,
Vlad Yasevich <vladislav.yasevich@hp.com>,
linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-sctp@vger.kernel.org
Subject: [PATCH] sctp: fix sctp_setsockopt_autoclose compile warning
Date: Mon, 30 Nov 2009 10:52:50 +0100 [thread overview]
Message-ID: <20091130095250.GZ10897@shell.iptel.org> (raw)
In-Reply-To: <20091130094929.GY10897@shell.iptel.org>
Fix the following warning, when building on 64 bits:
net/sctp/socket.c:2091: warning: large integer implicitly
truncated to unsigned type
Signed-off-by: Andrei Pelinescu-Onciul <andrei@iptel.org>
---
net/sctp/socket.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/sctp/socket.c b/net/sctp/socket.c
index 71513b3..8961863 100644
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -2088,7 +2088,7 @@ static int sctp_setsockopt_autoclose(struct sock *sk, char __user *optval,
return -EFAULT;
/* make sure it won't exceed MAX_SCHEDULE_TIMEOUT */
if (sp->autoclose > (MAX_SCHEDULE_TIMEOUT / HZ) )
- sp->autoclose = MAX_SCHEDULE_TIMEOUT / HZ ;
+ sp->autoclose = (__u32)(MAX_SCHEDULE_TIMEOUT / HZ) ;
return 0;
}
--
1.6.5.3
WARNING: multiple messages have this Message-ID (diff)
From: Andrei Pelinescu-Onciul <andrei@iptel.org>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: "David S. Miller" <davem@davemloft.net>,
Vlad Yasevich <vladislav.yasevich@hp.com>,
linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-sctp@vger.kernel.org
Subject: [PATCH] sctp: fix sctp_setsockopt_autoclose compile warning
Date: Mon, 30 Nov 2009 09:52:50 +0000 [thread overview]
Message-ID: <20091130095250.GZ10897@shell.iptel.org> (raw)
In-Reply-To: <20091130094929.GY10897@shell.iptel.org>
Fix the following warning, when building on 64 bits:
net/sctp/socket.c:2091: warning: large integer implicitly
truncated to unsigned type
Signed-off-by: Andrei Pelinescu-Onciul <andrei@iptel.org>
---
net/sctp/socket.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/sctp/socket.c b/net/sctp/socket.c
index 71513b3..8961863 100644
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -2088,7 +2088,7 @@ static int sctp_setsockopt_autoclose(struct sock *sk, char __user *optval,
return -EFAULT;
/* make sure it won't exceed MAX_SCHEDULE_TIMEOUT */
if (sp->autoclose > (MAX_SCHEDULE_TIMEOUT / HZ) )
- sp->autoclose = MAX_SCHEDULE_TIMEOUT / HZ ;
+ sp->autoclose = (__u32)(MAX_SCHEDULE_TIMEOUT / HZ) ;
return 0;
}
--
1.6.5.3
next prev parent reply other threads:[~2009-11-30 9:52 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-30 5:40 linux-next: net tree build warning Stephen Rothwell
2009-11-30 9:49 ` Andrei Pelinescu-Onciul
2009-11-30 9:52 ` Andrei Pelinescu-Onciul [this message]
2009-11-30 9:52 ` [PATCH] sctp: fix sctp_setsockopt_autoclose compile warning Andrei Pelinescu-Onciul
2009-11-30 10:06 ` David Miller
2009-11-30 10:06 ` David Miller
2009-12-01 19:02 ` Vlad Yasevich
2009-12-01 19:02 ` Vlad Yasevich
2009-12-02 9:17 ` David Miller
2009-12-02 9:17 ` David Miller
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=20091130095250.GZ10897@shell.iptel.org \
--to=andrei@iptel.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=linux-sctp@vger.kernel.org \
--cc=sfr@canb.auug.org.au \
--cc=vladislav.yasevich@hp.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.