Message ID | 20220428121033.1609620-2-muhammad_hamza@mentor.com |
---|---|
State | Accepted |
Headers | show |
Series | [1/3,meta-swupdate,v1,1/3] swupdate-usb: update service to use mount points dynamically | expand |
On 28.04.22 14:10, Muhammad Hamza wrote: > There is a true dependecy of swupdate-usb service on swupdate > service which is not present in a proper way. If swupdate is > not running for some reason, the swupdate-usb service will fail > as swupdate-client requires the host socket to be present which > is provided by host. > In current implementation swupdate-usb has a dependedency on > swupdate-progress which does not have a "Requires" dependency > on swupdate. This results in a failure if swupdate service is not > running and swupdate-usb tries to invoke swupdate-client. > The swupdate-sb must have a direct dependency on swupdate service > because we might have systems where one does not want to monitor > progress. Therefore any changes in current dependency chain will > result in failure for swupdate. > Therefore a "Require" dependency on swupdate service must be > present in swupdate-usb. swsupdate-usb does not require > swupdate-progress service to be present or running for a successful > update but it does need swupdate.service to be up and running to > run. This is makes it a true dependency. > This commit changes swupdate-usb to require swsupdate service to > have a proper and right dedpendency. > > Signed-off-by: Muhammad Hamza <muhammad_hamza@mentor.com> > --- > recipes-support/swupdate/swupdate/swupdate-usb@.service | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/recipes-support/swupdate/swupdate/swupdate-usb@.service b/recipes-support/swupdate/swupdate/swupdate-usb@.service > index 752253e..cf5dcaf 100644 > --- a/recipes-support/swupdate/swupdate/swupdate-usb@.service > +++ b/recipes-support/swupdate/swupdate/swupdate-usb@.service > @@ -1,5 +1,6 @@ > [Unit] > Description=usb media swupdate service > +Requires=swupdate.service > Requires=swupdate-progress.service > > [Service] Acked-by: Stefano Babic <sbabic@denx.de> Best regards, Stefano Babic
diff --git a/recipes-support/swupdate/swupdate/swupdate-usb@.service b/recipes-support/swupdate/swupdate/swupdate-usb@.service index 752253e..cf5dcaf 100644 --- a/recipes-support/swupdate/swupdate/swupdate-usb@.service +++ b/recipes-support/swupdate/swupdate/swupdate-usb@.service @@ -1,5 +1,6 @@ [Unit] Description=usb media swupdate service +Requires=swupdate.service Requires=swupdate-progress.service [Service]
There is a true dependecy of swupdate-usb service on swupdate service which is not present in a proper way. If swupdate is not running for some reason, the swupdate-usb service will fail as swupdate-client requires the host socket to be present which is provided by host. In current implementation swupdate-usb has a dependedency on swupdate-progress which does not have a "Requires" dependency on swupdate. This results in a failure if swupdate service is not running and swupdate-usb tries to invoke swupdate-client. The swupdate-sb must have a direct dependency on swupdate service because we might have systems where one does not want to monitor progress. Therefore any changes in current dependency chain will result in failure for swupdate. Therefore a "Require" dependency on swupdate service must be present in swupdate-usb. swsupdate-usb does not require swupdate-progress service to be present or running for a successful update but it does need swupdate.service to be up and running to run. This is makes it a true dependency. This commit changes swupdate-usb to require swsupdate service to have a proper and right dedpendency. Signed-off-by: Muhammad Hamza <muhammad_hamza@mentor.com> --- recipes-support/swupdate/swupdate/swupdate-usb@.service | 1 + 1 file changed, 1 insertion(+)