Re: [linux-pm] [PATCH 2/4] ACPI hibernate: Add a mechanism to save/restore ACPI NVS memory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

> > >  #else /* CONFIG_HIBERNATION */
> > >  static inline int swsusp_page_is_forbidden(struct page *p) { return 0; }
> > >  static inline void swsusp_set_page_free(struct page *p) {}
> > > @@ -241,6 +246,14 @@ static inline void swsusp_unset_page_fre
> > >  static inline void hibernation_set_ops(struct platform_hibernation_ops *ops) {}
> > >  static inline int hibernate(void) { return -ENOSYS; }
> > >  static inline bool system_entering_hibernation(void) { return false; }
> > > +static inline int hibernate_nvs_register(unsigned long a, unsigned long b)
> > > +{
> > > +	return 0;
> > > +}
> > > +static inline int hibernate_nvs_alloc(void) { return 0; }
> > > +static inline void hibernate_nvs_free(void) {}
> > > +static inline void hibernate_nvs_save(void) {}
> > > +static inline void hibernate_nvs_restore(void) {}
> > >  #endif /* CONFIG_HIBERNATION */
> > 
> > Can someone call these for !hibernation case?
> 
> Not at the moment, but why not to add them?

Well, someone may call them, expecting them to save / restore nvs,
except that they will not be there. I'd prefer inlines not to exist
(so mistake is caught at compile time) or them to contain BUG(), so
that mistake is obvious.
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux