Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hw/arm/aspeed:Added mmc boot support for AST2600 eMMC image. #35

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

shitalkumar-gandhi
Copy link

This patch has been added to boot eMMC image for AST2600 machine on
QEMU.

Run quemu as follows:

./qemu-system-arm -m 1G -M ast2600-evb -nographic -drive
file=mmc-evb-ast2600.img,format=raw,if=sd,index=2

Tested: Booted AST2600 eMMC image on QEMU.
Signed-off-by: Shitalkumar Gandhi shitalkumar.gandhi@seagate.com

This patch has been added to boot eMMC image for AST2600 machine on
QEMU.

Run quemu as follows:

./qemu-system-arm -m 1G -M ast2600-evb -nographic -drive
file=mmc-evb-ast2600.img,format=raw,if=sd,index=2

Tested: Booted AST2600 eMMC image on QEMU.
Signed-off-by: Shitalkumar Gandhi <shitalkumar.gandhi@seagate.com>
@shitalkumar-gandhi
Copy link
Author

@williamspatrick @amboar @legoater @shenki please review.

@amboar
Copy link
Member

amboar commented Nov 23, 2021

Hi @shitalkumar-gandhi , thanks for the patch. For qemu we try to do upstream first and only accept downstream patches if it's truly necessary (usually outright hacks that have an unfortunate bang-for-buck value).

That said you should review the conversation here on this exact topic: openbmc/openbmc#3818 . It's hard to say how the ast2600 evb boot configuration should be managed, and worse, because of the situation upstream with eMMC it's hard to see an way forward that isn't a minefield. Anyway, if you have some thoughts after reading the linked thread I'm interested to hear them :)

@legoater
Copy link

@shitalkumar-gandhi, yes, the QEMU patches should be sent upstream on the qemu-devel mailing list and this patch is changing a default behavior :/ I think the right approach would be to use the boot index of the device on the command line.

Could you please check an alternate and easier approach in https://github.com/legoater/qemu/commits/aspeed-6.2 ? The changes add a boot-emmc machine option to set/unset the emmc boot.

To boot from emmc on the ast2600-evb QEMU machine, you will need to use option -M ast2600-evb,boot-emmc=true

@amboar @shenki Could you give it a try ? Thanks.

@shitalkumar-gandhi
Copy link
Author

Hi @legoater

The following option is not working in QEMU for eMMC boot.
-M ast2600-evb,boot-emmc=true

Hi @amboar

I don't have the alternate approach. I feel this change should be included in QEMU's upstream.

Please let me know what you think about this.
Thanks to all for the responses.

@amboar
Copy link
Member

amboar commented Nov 29, 2021

@shitalkumar-gandhi this change won't be acceptable upstream as is because it prevents booting from SPI-NOR (by forcing the boot source to eMMC). Either boot source is valid for the EVB, so we need a solution that allows for both.

@legoater
Copy link

@shitalkumar-gandhi which QEMU repository and which branch are you using ?

@shitalkumar-gandhi
Copy link
Author

ok @amboar thanks got it, we should have a mechanism that permits both eMMC and flash booting.
@legoater I am using your repo i.e. https://github.com/legoater/qemu and aspeed-6.2 branch.

@legoater
Copy link

Could you please give us the command line, the reported errors and access to the eMMC image you are using. Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants