blob: c5f75501ca154ca24a5f0d6db73e36ea763e47ff [file] [log] [blame]
/*
* Copyright (C) 2014 Motorola Mobility LLC.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 as published by
* the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef M4SENSORHUB_NOTIFY_H
#define M4SENSORHUB_NOTIFY_H
#ifdef __KERNEL__
#include <linux/notifier.h>
/* some peripherals are hooked up on lines that M4 bootloader
is polling to see any activity. If any of these lines show
any kind of activity, M4 bootloader gets confused and can't be
recovered. So.. when we are trying to bring up M4, disable
these peripherals, and reenable them once M4 is up and running*/
enum m4sensor_request {
DISABLE_PERIPHERAL,
ENABLE_PERIPHERAL
};
extern void m4sensorhub_register_notify(struct notifier_block *nb);
extern void m4sensorhub_unregister_notify(struct notifier_block *nb);
extern void m4sensorhub_notify_subscriber(unsigned long event);
#endif /* __KERNEL__ */
#endif /* M4SENSORHUB_NOTIFY_H */