summaryrefslogtreecommitdiff
path: root/Documentation/gcc-plugins.txt
diff options
context:
space:
mode:
authorAnton Vasilyev <vasilyev@ispras.ru>2018-07-24 18:10:38 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-08-02 10:34:12 +0200
commit45ca3f76de0507ecf143f770570af2942f263812 (patch)
tree67c46e293ee4ae084edbf390f7bede3e21bc2b94 /Documentation/gcc-plugins.txt
parent9a481bdc16294414fa4d666ab4f4019224d880a5 (diff)
firmware: vpd: Fix section enabled flag on vpd_section_destroy
static struct ro_vpd and rw_vpd are initialized by vpd_sections_init() in vpd_probe() based on header's ro and rw sizes. In vpd_remove() vpd_section_destroy() performs deinitialization based on enabled flag, which is set to true by vpd_sections_init(). This leads to call of vpd_section_destroy() on already destroyed section for probe-release-probe-release sequence if first probe performs ro_vpd initialization and second probe does not initialize it. The patch adds changing enabled flag on vpd_section_destroy and adds cleanup on the error path of vpd_sections_init. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Anton Vasilyev <vasilyev@ispras.ru> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation/gcc-plugins.txt')
0 files changed, 0 insertions, 0 deletions