diff options
author | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-06-24 17:02:50 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-06-24 17:02:50 +1000 |
commit | e3e38fcc77e49378db230f06b5f38e3814229aae (patch) | |
tree | f8f807f23a40801b9ae46cb59569cd3b3f737679 /include | |
parent | e5b053749e75e959aa5cafc875327b66f571e73a (diff) | |
download | skiboot-e3e38fcc77e49378db230f06b5f38e3814229aae.zip skiboot-e3e38fcc77e49378db230f06b5f38e3814229aae.tar.gz skiboot-e3e38fcc77e49378db230f06b5f38e3814229aae.tar.bz2 |
Move NVRAM format/check code out into separate file to unit test
We (slightly) change the internal API so that we operate on parameters
rather than globals, this means it's easier to unit test too.
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/nvram-format.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/include/nvram-format.h b/include/nvram-format.h new file mode 100644 index 0000000..693f0bd --- /dev/null +++ b/include/nvram-format.h @@ -0,0 +1,23 @@ +/* Copyright 2013-2014 IBM Corp. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + * implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef __NVRAM_FORMAT_H +#define __NVRAM_FORMAT_H + +void nvram_format(void *nvram_image, uint32_t nvram_size); +int nvram_check(void *nvram_image, uint32_t nvram_size); + +#endif /* __NVRAM_FORMAT_H */ |