Commit 754beeec authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'char-misc-5.6-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc

Pull char/misc fix from Greg KH:
 "Here is a single patch, that fixes up a commit that came in the
  previous char/misc merge.

  It fixes a bug in the hpet driver that everyone keeps tripping over in
  their automated testing. Good thing is, people are catching it. Bad
  thing it wasn't caught by anyone testing before this. Oh well...

  This has been in linux-next for a few days with no reported issues"

* tag 'char-misc-5.6-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
  char: hpet: Fix out-of-bounds read bug
parents 2367da5b 98c49f17
...@@ -855,7 +855,7 @@ int hpet_alloc(struct hpet_data *hdp) ...@@ -855,7 +855,7 @@ int hpet_alloc(struct hpet_data *hdp)
return 0; return 0;
} }
hpetp = kzalloc(struct_size(hpetp, hp_dev, hdp->hd_nirqs - 1), hpetp = kzalloc(struct_size(hpetp, hp_dev, hdp->hd_nirqs),
GFP_KERNEL); GFP_KERNEL);
if (!hpetp) if (!hpetp)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment