Skip to content

Commit

Permalink
mac80211: disallow seeks in minstrel debug code
Browse files Browse the repository at this point in the history
No need for seek here, so let's just use nonseekable_open.

Signed-off-by: Arnd Bergmann <[email protected]>
  • Loading branch information
arndb committed Sep 16, 2010
1 parent d9d2e9d commit a0572d9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion net/mac80211/rc80211_minstrel_ht_debugfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,14 +90,15 @@ minstrel_ht_stats_open(struct inode *inode, struct file *file)
MINSTREL_TRUNC(mi->avg_ampdu_len * 10) % 10);
ms->len = p - ms->buf;

return 0;
return nonseekable_open(inode, file);
}

static const struct file_operations minstrel_ht_stat_fops = {
.owner = THIS_MODULE,
.open = minstrel_ht_stats_open,
.read = minstrel_stats_read,
.release = minstrel_stats_release,
.llseek = no_llseek,
};

void
Expand Down

0 comments on commit a0572d9

Please sign in to comment.