diff options
author | Ionut Nicu <ionut.nicu@freescale.com> | 2008-03-07 12:27:59 -0500 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2008-03-10 14:07:27 -0400 |
commit | 86f4e5d4335556191b436b41b0ad2f719c4a98d4 (patch) | |
tree | 8aa1f2453df03df59037d69fc263a389dc3a94da /arch | |
parent | ad562c71592ae76440c27bba9bfa9c16cc851560 (diff) |
[POWERPC] QE: Make qe_get_firmware_info reentrant
The function was returning NULL the second time it was
called if the firmware was uploaded from the boot loader
or the first time it was called if the firmware was
uploaded from the kernel.
Signed-off-by: Ionut Nicu <ionut.nicu@freescale.com>
Acked-By: Timur Tabi <timur@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/powerpc/sysdev/qe_lib/qe.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/powerpc/sysdev/qe_lib/qe.c b/arch/powerpc/sysdev/qe_lib/qe.c index f963fbf21ef..cc81fd1141b 100644 --- a/arch/powerpc/sysdev/qe_lib/qe.c +++ b/arch/powerpc/sysdev/qe_lib/qe.c | |||
@@ -609,7 +609,10 @@ struct qe_firmware_info *qe_get_firmware_info(void) | |||
609 | * If we haven't checked yet, and a driver hasn't uploaded a firmware | 609 | * If we haven't checked yet, and a driver hasn't uploaded a firmware |
610 | * yet, then check the device tree for information. | 610 | * yet, then check the device tree for information. |
611 | */ | 611 | */ |
612 | if (initialized || qe_firmware_uploaded) | 612 | if (qe_firmware_uploaded) |
613 | return &qe_firmware_info; | ||
614 | |||
615 | if (initialized) | ||
613 | return NULL; | 616 | return NULL; |
614 | 617 | ||
615 | initialized = 1; | 618 | initialized = 1; |