scripts: sd_fusing: wait for udev after sfdisk
authorJacek Kryszyn <j.kryszyn@samsung.com>
Mon, 10 Jun 2024 06:45:41 +0000 (08:45 +0200)
committerJaehoon Chung <jh80.chung@samsung.com>
Mon, 28 Oct 2024 11:28:45 +0000 (20:28 +0900)
commitf8d6d641a664a9c9a3701bd0c83c02185348fd85
treeff9e977390fb61ca5dc80e40ce218084ca27a745
parentb766575a2a1b0618a14a549ac0c6f3304128320f
scripts: sd_fusing: wait for udev after sfdisk

It was observed that errors related to wrong partition table
were thrown from time to time after repartitoning the device
with sfdisk. It seems that this was due to udev trying to
automatically rescan devices after being notified that some
changes were made.

This commit adds execution of udevadm settle after sfdisk.
The added command exits only after the udev event queue is
empty (or the timeout occured).

This commit reverts changes made by commit 5a7f3c8 (Invoke
ioctl to reread partitions directly) which are not needed
anymore. Running blockdev after sfdisk is also unnecessary
since sfdisk rereads the partition table anyway.

Change-Id: Ic89ea65846b4e064c85a316fdf6c07be42eb51e7
Signed-off-by: Jacek Kryszyn <j.kryszyn@samsung.com>
scripts/tizen/sd_fusing.py