Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 57827
b: refs/heads/master
c: ce9b2b0
h: refs/heads/master
i:
  57825: 079d4f4
  57823: 3b4a449
v: v3
  • Loading branch information
Rafael J. Wysocki authored and Bartlomiej Zolnierkiewicz committed Jun 16, 2007
1 parent 027ea2d commit 7b80134
Show file tree
Hide file tree
Showing 10 changed files with 14 additions and 42 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fa04a008a16ac633a55f41baf9e84b551e613e7e
refs/heads/master: ce9b2b0abbf019d5259eb089a1cc256852930f67
9 changes: 6 additions & 3 deletions trunk/drivers/ide/ide.c
Original file line number Diff line number Diff line change
Expand Up @@ -1010,7 +1010,6 @@ static int generic_ide_resume(struct device *dev)
{
ide_drive_t *drive = dev->driver_data;
ide_hwif_t *hwif = HWIF(drive);
ide_driver_t *drv = to_ide_driver(dev->driver);
struct request rq;
struct request_pm_state rqpm;
ide_task_t args;
Expand All @@ -1033,8 +1032,12 @@ static int generic_ide_resume(struct device *dev)

err = ide_do_drive_cmd(drive, &rq, ide_head_wait);

if (err == 0 && drv && drv->resume)
drv->resume(drive);
if (err == 0 && dev->driver) {
ide_driver_t *drv = to_ide_driver(dev->driver);

if (drv->resume)
drv->resume(drive);
}

return err;
}
Expand Down
12 changes: 0 additions & 12 deletions trunk/include/linux/ktime.h
Original file line number Diff line number Diff line change
Expand Up @@ -261,18 +261,6 @@ static inline s64 ktime_to_ns(const ktime_t kt)

#endif

/**
* ktime_equal - Compares two ktime_t variables to see if they are equal
* @cmp1: comparable1
* @cmp2: comparable2
*
* Compare two ktime_t variables, returns 1 if equal
*/
static inline int ktime_equal(const ktime_t cmp1, const ktime_t cmp2)
{
return cmp1.tv64 == cmp2.tv64;
}

static inline s64 ktime_to_us(const ktime_t kt)
{
struct timeval tv = ktime_to_timeval(kt);
Expand Down
4 changes: 0 additions & 4 deletions trunk/include/linux/skbuff.h
Original file line number Diff line number Diff line change
Expand Up @@ -1579,10 +1579,6 @@ static inline ktime_t net_timedelta(ktime_t t)
return ktime_sub(ktime_get_real(), t);
}

static inline ktime_t net_invalid_timestamp(void)
{
return ktime_set(0, 0);
}

extern __sum16 __skb_checksum_complete_head(struct sk_buff *skb, int len);
extern __sum16 __skb_checksum_complete(struct sk_buff *skb);
Expand Down
3 changes: 0 additions & 3 deletions trunk/net/ipv4/tcp_illinois.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,6 @@ static void tcp_illinois_acked(struct sock *sk, u32 pkts_acked, ktime_t last)

ca->acked = pkts_acked;

if (ktime_equal(last, net_invalid_timestamp()))
return;

rtt = ktime_to_us(net_timedelta(last));

/* ignore bogus values, this prevents wraparound in alpha math */
Expand Down
15 changes: 5 additions & 10 deletions trunk/net/ipv4/tcp_input.c
Original file line number Diff line number Diff line change
Expand Up @@ -953,7 +953,7 @@ tcp_sacktag_write_queue(struct sock *sk, struct sk_buff *ack_skb, u32 prior_snd_
int prior_fackets;
u32 lost_retrans = 0;
int flag = 0;
int found_dup_sack = 0;
int dup_sack = 0;
int cached_fack_count;
int i;
int first_sack_index;
Expand All @@ -964,20 +964,20 @@ tcp_sacktag_write_queue(struct sock *sk, struct sk_buff *ack_skb, u32 prior_snd_

/* Check for D-SACK. */
if (before(ntohl(sp[0].start_seq), TCP_SKB_CB(ack_skb)->ack_seq)) {
found_dup_sack = 1;
dup_sack = 1;
tp->rx_opt.sack_ok |= 4;
NET_INC_STATS_BH(LINUX_MIB_TCPDSACKRECV);
} else if (num_sacks > 1 &&
!after(ntohl(sp[0].end_seq), ntohl(sp[1].end_seq)) &&
!before(ntohl(sp[0].start_seq), ntohl(sp[1].start_seq))) {
found_dup_sack = 1;
dup_sack = 1;
tp->rx_opt.sack_ok |= 4;
NET_INC_STATS_BH(LINUX_MIB_TCPDSACKOFORECV);
}

/* D-SACK for already forgotten data...
* Do dumb counting. */
if (found_dup_sack &&
if (dup_sack &&
!after(ntohl(sp[0].end_seq), prior_snd_una) &&
after(ntohl(sp[0].end_seq), tp->undo_marker))
tp->undo_retrans--;
Expand Down Expand Up @@ -1058,7 +1058,6 @@ tcp_sacktag_write_queue(struct sock *sk, struct sk_buff *ack_skb, u32 prior_snd_
__u32 start_seq = ntohl(sp->start_seq);
__u32 end_seq = ntohl(sp->end_seq);
int fack_count;
int dup_sack = (found_dup_sack && (i == first_sack_index));

skb = cached_skb;
fack_count = cached_fack_count;
Expand Down Expand Up @@ -2410,7 +2409,7 @@ static int tcp_clean_rtx_queue(struct sock *sk, __s32 *seq_rtt_p)
int acked = 0;
int prior_packets = tp->packets_out;
__s32 seq_rtt = -1;
ktime_t last_ackt = net_invalid_timestamp();
ktime_t last_ackt = ktime_set(0,0);

while ((skb = tcp_write_queue_head(sk)) &&
skb != tcp_send_head(sk)) {
Expand Down Expand Up @@ -2488,10 +2487,6 @@ static int tcp_clean_rtx_queue(struct sock *sk, __s32 *seq_rtt_p)
tcp_ack_update_rtt(sk, acked, seq_rtt);
tcp_ack_packets_out(sk);

/* Is the ACK triggering packet unambiguous? */
if (acked & FLAG_RETRANS_DATA_ACKED)
last_ackt = net_invalid_timestamp();

if (ca_ops->pkts_acked)
ca_ops->pkts_acked(sk, pkts_acked, last_ackt);
}
Expand Down
3 changes: 1 addition & 2 deletions trunk/net/ipv4/tcp_lp.c
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,7 @@ static void tcp_lp_pkts_acked(struct sock *sk, u32 num_acked, ktime_t last)
struct tcp_sock *tp = tcp_sk(sk);
struct lp *lp = inet_csk_ca(sk);

if (!ktime_equal(last, net_invalid_timestamp()))
tcp_lp_rtt_sample(sk, ktime_to_us(net_timedelta(last)));
tcp_lp_rtt_sample(sk, ktime_to_us(net_timedelta(last)));

/* calc inference */
if (tcp_time_stamp > tp->rx_opt.rcv_tsecr)
Expand Down
3 changes: 0 additions & 3 deletions trunk/net/ipv4/tcp_vegas.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,6 @@ void tcp_vegas_pkts_acked(struct sock *sk, u32 cnt, ktime_t last)
struct vegas *vegas = inet_csk_ca(sk);
u32 vrtt;

if (ktime_equal(last, net_invalid_timestamp()))
return;

/* Never allow zero rtt or baseRTT */
vrtt = ktime_to_us(net_timedelta(last)) + 1;

Expand Down
3 changes: 0 additions & 3 deletions trunk/net/ipv4/tcp_veno.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,6 @@ static void tcp_veno_pkts_acked(struct sock *sk, u32 cnt, ktime_t last)
struct veno *veno = inet_csk_ca(sk);
u32 vrtt;

if (ktime_equal(last, net_invalid_timestamp()))
return;

/* Never allow zero rtt or baseRTT */
vrtt = ktime_to_us(net_timedelta(last)) + 1;

Expand Down
2 changes: 1 addition & 1 deletion trunk/net/rxrpc/ar-connection.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ static struct rxrpc_connection *rxrpc_alloc_connection(gfp_t gfp)
conn->header_size = sizeof(struct rxrpc_header);
}

_leave(" = %p{%d}", conn, conn ? conn->debug_id : 0);
_leave(" = %p{%d}", conn, conn->debug_id);
return conn;
}

Expand Down

0 comments on commit 7b80134

Please sign in to comment.