|
@@ -177,10 +177,10 @@ recent_entry_init(struct recent_table *t, const union nf_inet_addr *addr,
|
|
|
|
|
|
static void recent_entry_update(struct recent_table *t, struct recent_entry *e)
|
|
static void recent_entry_update(struct recent_table *t, struct recent_entry *e)
|
|
{
|
|
{
|
|
|
|
+ e->index %= ip_pkt_list_tot;
|
|
e->stamps[e->index++] = jiffies;
|
|
e->stamps[e->index++] = jiffies;
|
|
if (e->index > e->nstamps)
|
|
if (e->index > e->nstamps)
|
|
e->nstamps = e->index;
|
|
e->nstamps = e->index;
|
|
- e->index %= ip_pkt_list_tot;
|
|
|
|
list_move_tail(&e->lru_list, &t->lru_list);
|
|
list_move_tail(&e->lru_list, &t->lru_list);
|
|
}
|
|
}
|
|
|
|
|