Repository: incubator-mynewt-core Updated Branches: refs/heads/develop 265f67019 -> 0bfa75530
MYNEWT-491 Prevent repeated package initialization Forgot to commit this file! Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/0bfa7553 Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/0bfa7553 Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/0bfa7553 Branch: refs/heads/develop Commit: 0bfa75530ff84b9b471a1bd784ce8eaa8cddbc74 Parents: 265f670 Author: Christopher Collins <ccoll...@apache.org> Authored: Wed Nov 30 18:16:13 2016 -0800 Committer: Christopher Collins <ccoll...@apache.org> Committed: Wed Nov 30 18:16:13 2016 -0800 ---------------------------------------------------------------------- sys/sysinit/src/sysinit.c | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/0bfa7553/sys/sysinit/src/sysinit.c ---------------------------------------------------------------------- diff --git a/sys/sysinit/src/sysinit.c b/sys/sysinit/src/sysinit.c new file mode 100644 index 0000000..e8430d0 --- /dev/null +++ b/sys/sysinit/src/sysinit.c @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you 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. + */ + +#include "sysinit/sysinit.h" + +uint8_t sysinit_active; + +void +sysinit_start(void) +{ + sysinit_active = 1; +} + +void +sysinit_end(void) +{ + sysinit_active = 0; +}