Skip to content

Commit

Permalink
aty: use memory_read_from_buffer()
Browse files Browse the repository at this point in the history
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Cc: Krzysztof Helt <krzysztof.h1@poczta.fm>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Akinobu Mita authored and Linus Torvalds committed Jul 24, 2008
1 parent 1c554ff commit a882ef4
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions drivers/video/aty/radeon_base.c
Original file line number Diff line number Diff line change
Expand Up @@ -2098,15 +2098,7 @@ static void radeon_identify_vram(struct radeonfb_info *rinfo)

static ssize_t radeon_show_one_edid(char *buf, loff_t off, size_t count, const u8 *edid)
{
if (off > EDID_LENGTH)
return 0;

if (off + count > EDID_LENGTH)
count = EDID_LENGTH - off;

memcpy(buf, edid + off, count);

return count;
return memory_read_from_buffer(buf, count, &off, edid, EDID_LENGTH);
}


Expand Down

0 comments on commit a882ef4

Please sign in to comment.