Message ID | 1432811625-13392-5-git-send-email-zhaoshenglong@huawei.com |
---|---|
State | New |
Headers | show |
Applied to -trivial, thanks! /mjt
28.05.2015 14:54, Michael Tokarev wrote:
> Applied to -trivial, thanks!
..or not applied yet... :)
This is again the same situation with the error message as with
1/4 hw/display/cg3.c, and the same question - is the error fatal?
And note that you're the number-one person who made changes to
this file... ;)
/mjt
On 28/05/15 13:01, Michael Tokarev wrote: > 28.05.2015 14:54, Michael Tokarev wrote: >> Applied to -trivial, thanks! > > ..or not applied yet... :) > > This is again the same situation with the error message as with > 1/4 hw/display/cg3.c, and the same question - is the error fatal? > > And note that you're the number-one person who made changes to > this file... ;) > > /mjt The FCode ROMs supplied for CG3/TCX are used to both initialise various DT entries for the graphic adapters and also provide a minimal driver to allow OpenBIOS (or Sun PROM) to initialise and use the adapter at boot. I'd say at the moment the error should be fatal, since the correct way to have a headless system would be not to have the virtual graphics adapter plugged into the system in the first place. Otherwise I can see that the skeleton DT nodes generated by the PROM would be missing several properties generated by the FCode (such as the framebuffer address), which would be utterly confusing for any client trying to use the graphics adapter. ATB, Mark.
28.05.2015 15:19, Mark Cave-Ayland wrote: [] > The FCode ROMs supplied for CG3/TCX are used to both initialise various > DT entries for the graphic adapters and also provide a minimal driver to > allow OpenBIOS (or Sun PROM) to initialise and use the adapter at boot. > > I'd say at the moment the error should be fatal, [...] So it looks like some exit(1) or similar is missing after error_report() in these cases, which should be added :) Thanks! /mjt
diff --git a/hw/display/tcx.c b/hw/display/tcx.c index a9f9f66..6c5e584 100644 --- a/hw/display/tcx.c +++ b/hw/display/tcx.c @@ -1014,6 +1014,7 @@ static void tcx_realizefn(DeviceState *dev, Error **errp) if (fcode_filename) { ret = load_image_targphys(fcode_filename, s->prom_addr, FCODE_MAX_ROM_SIZE); + g_free(fcode_filename); if (ret < 0 || ret > FCODE_MAX_ROM_SIZE) { error_report("tcx: could not load prom '%s'", TCX_ROM_FILE); }