rtc: omap: fix missing wakealarm attribute
rtc: omap: fix missing wakealarm attribute

The platform device must be registered as wakeup capable before
registering the class device, or the wakealarm attribute will not be
created.

Also make sure to unregister the wakeup source on probe errors.

Fixes: 1d2e2b65d098 ("rtc: omap: restore back (hard-code) wakeup support")
Signed-off-by: Johan Hovold <759412786bc533369b22377bf83fb9056c5b25b2@kernel.org>
Reviewed-by: Felipe Balbi <94dddeeef08b001e003cce128ddc162a4e2c6cd2@ti.com>
Tested-by: Felipe Balbi <94dddeeef08b001e003cce128ddc162a4e2c6cd2@ti.com>
Cc: Alessandro Zummo <f0b9bd96bf07bfecc189c62159960134588fafe5@towertech.it>
Cc: Tony Lindgren <1001e8702733cced254345e193c88aaa47a4f5de@atomide.com>
Cc: Benot Cousson <8341a8614128d333cb43eedf99ddd6472c68ff67@baylibre.com>
Cc: Lokesh Vutla <c1574519d727edaf2e16b260e452051ef77bf018@ti.com>
Cc: Guenter Roeck <ba324ca7b1c77fc20bb970d5aff6eea9377918a5@roeck-us.net>
Cc: Sekhar Nori <946cfb81282bb55c59f600e7ee3d3b2c6973f7a3@ti.com>
Cc: Tero Kristo <060a12f1fbc7e2e5d830b72f402ff04fdae8d312@ti.com>
Cc: Keerthy J <bd0da4b944f4f5c71572cb1afabf3c293f45b4c8@ti.com>
Cc: <4fbacc2fa0ffdbb11bf1ad6925b886ebd08dd15f@vger.kernel.org>
Signed-off-by: Andrew Morton <5c1e68b099950c134891f0b6e179498a8ebe9cf9@linux-foundation.org>
Signed-off-by: Linus Torvalds <69652caca27c8b940640ad396ab71f93cacec34f@linux-foundation.org>

KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs