]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
sdp: fixed signedness warning in compilation + don't use getnstimeofday
authorAmir Vadai <amirv@mellanox.co.il>
Sun, 9 Aug 2009 08:15:44 +0000 (11:15 +0300)
committerMukesh Kacker <mukesh.kacker@oracle.com>
Tue, 6 Oct 2015 12:04:36 +0000 (05:04 -0700)
Signed-off-by: Amir Vadai <amirv@mellanox.co.il>
drivers/infiniband/ulp/sdp/sdp.h
drivers/infiniband/ulp/sdp/sdp_zcopy.c

index 7881afa7f7d4492d041a5d50112c5a8aee47a8b2..f5a46ea208d095fb889c726278b8cf03a73297e3 100644 (file)
@@ -57,12 +57,6 @@ struct sdpprf_log {
 extern struct sdpprf_log sdpprf_log[SDPPRF_LOG_SIZE];
 extern int sdpprf_log_count;
 
-static inline unsigned long long current_nsec(void)
-{
-       struct timespec tv;
-       getnstimeofday(&tv);
-       return tv.tv_sec * NSEC_PER_SEC + tv.tv_nsec;
-}
 #define sdp_prf1(sk, s, format, arg...) ({ \
        struct sdpprf_log *l = \
                &sdpprf_log[sdpprf_log_count++ & (SDPPRF_LOG_SIZE - 1)]; \
@@ -74,7 +68,7 @@ static inline unsigned long long current_nsec(void)
        l->cpu = smp_processor_id(); \
        l->skb = s; \
        snprintf(l->msg, sizeof(l->msg) - 1, format, ## arg); \
-       l->time = current_nsec(); \
+       l->time = jiffies_to_usecs(jiffies); \
        l->func = __func__; \
        l->line = __LINE__; \
        preempt_enable(); \
index f3c0bef9fee5f08c3cc9380b2cd99719c69a9dce..185b85be51d690fcc40ca52a709eb50560eb5a05 100644 (file)
@@ -39,7 +39,6 @@
 #include <rdma/rdma_cm.h>
 #include <rdma/ib_verbs.h>
 #include <rdma/ib_fmr_pool.h>
-#include <linux/dmaengine.h>
 #include <linux/pagemap.h>
 #include <net/tcp.h> /* for memcpy_toiovec */
 #include <asm/io.h>
@@ -757,7 +756,7 @@ static int sdp_rdma_adv_single(struct sock *sk,
                int offset, int page_cnt, int len, u64 *addrs)
 {
        struct sdp_sock *ssk = sdp_sk(sk);
-       unsigned long timeo = SDP_SRCAVAIL_ADV_TIMEOUT; //sock_sndtimeo(sk, 0);
+       long timeo = SDP_SRCAVAIL_ADV_TIMEOUT;
        unsigned long lock_flags;
        int rc = 0;