RobertCNelson / boot-scripts

Just a bunch of useful scripts placed under /opt/scripts/
125 stars 132 forks source link

Pocket Beagle Generic Boot script #80

Open tesorrells opened 6 years ago

tesorrells commented 6 years ago

I'm trying to minimize the boot time on the pocket beagle while still retaining ssh capabilities. Generic boot script (and dev-mmcblk0p1, but that is the SD card, correct?) takes a ton of time, 35 seconds on average. I was reading on another post that you can get rid of the am335x_evm.sh call in generic-startup.sh, but to keep the serial capabilities you were referencing an .conf file that doesn't exist on the pocket beagle. What would be the best way to resolve this?

RobertCNelson commented 6 years ago

@tesorrells most of that delay is:

modprobe libcomposite

and then the configfs routine..

https://github.com/RobertCNelson/boot-scripts/blob/master/boot/am335x_evm.sh#L593-L603

Regards,

tesorrells commented 6 years ago

Would disabling this have any adverse effects?

RobertCNelson commented 6 years ago

nothing, unless you utilize the usb-gadget driver.. (usb flash/usb serial/usb networking)

tesorrells commented 6 years ago

Well I use USB to SSH into it, so I just need to retain that.

RobertCNelson commented 6 years ago

Well then your using something that cause 95% of the delay.. ;)

tesorrells commented 6 years ago

Ah, so I can't pick and choose the usb gadgets then. That makes sense. I already disabled the network and the mass storage but that didn't really effect it.

RobertCNelson commented 6 years ago

Well, there is a way to fix the delay. Move libcomposite as built-in..

You can see where i tried this here: (commented out section)

https://github.com/RobertCNelson/boot-scripts/blob/master/boot/am335x_evm.sh#L589-L608

But when built-in, the /sys/class/udc didn't populate:

https://github.com/RobertCNelson/boot-scripts/blob/master/boot/am335x_evm.sh#L533-L542

So i couldn't link the bus to the configfs setup..

Regards,