require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&_SYS_WDOG_H_)) {
    eval 'sub _SYS_WDOG_H_ () {1;}' unless defined(&_SYS_WDOG_H_);
    require 'sys/ioccom.ph';
    eval 'sub WDOG_NAMESIZE () {16;}' unless defined(&WDOG_NAMESIZE);
    eval 'sub WDOGIOC_GMODE () { &_IOWR(ord(\'w\'), 0, \'struct wdog_mode\');}' unless defined(&WDOGIOC_GMODE);
    eval 'sub WDOGIOC_SMODE () { &_IOW(ord(\'w\'), 1, \'struct wdog_mode\');}' unless defined(&WDOGIOC_SMODE);
    eval 'sub WDOGIOC_WHICH () { &_IOR(ord(\'w\'), 2, \'struct wdog_mode\');}' unless defined(&WDOGIOC_WHICH);
    eval 'sub WDOGIOC_TICKLE () { &_IO(ord(\'w\'), 3);}' unless defined(&WDOGIOC_TICKLE);
    eval 'sub WDOGIOC_GTICKLER () { &_IOR(ord(\'w\'), 4,  &pid_t);}' unless defined(&WDOGIOC_GTICKLER);
    eval 'sub WDOGIOC_GWDOGS () { &_IOWR(ord(\'w\'), 5, \'struct wdog_conf\');}' unless defined(&WDOGIOC_GWDOGS);
    eval 'sub WDOG_MODE_DISARMED () {0;}' unless defined(&WDOG_MODE_DISARMED);
    eval 'sub WDOG_MODE_KTICKLE () {1;}' unless defined(&WDOG_MODE_KTICKLE);
    eval 'sub WDOG_MODE_UTICKLE () {2;}' unless defined(&WDOG_MODE_UTICKLE);
    eval 'sub WDOG_MODE_ETICKLE () {3;}' unless defined(&WDOG_MODE_ETICKLE);
    eval 'sub WDOG_MODE_MASK () {0x3;}' unless defined(&WDOG_MODE_MASK);
    eval 'sub WDOG_FEATURE_ALARM () {0x10;}' unless defined(&WDOG_FEATURE_ALARM);
    eval 'sub WDOG_FEATURE_MASK () {0x10;}' unless defined(&WDOG_FEATURE_MASK);
    eval 'sub WDOG_PERIOD_DEFAULT () {(-1);}' unless defined(&WDOG_PERIOD_DEFAULT);
    eval 'sub WDOG_PERIOD_TO_TICKS {
        my($period) = @_;
	    eval q((($period) *  &hz));
    }' unless defined(&WDOG_PERIOD_TO_TICKS);
}
1;
