require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&__NVMEIO_H__)) {
    eval 'sub __NVMEIO_H__ () {1;}' unless defined(&__NVMEIO_H__);
    require 'sys/endian.ph';
    require 'sys/ioccom.ph';
    require 'dev/ic/nvmereg.ph';
    eval 'sub NVME_PASSTHROUGH_CMD () { &_IOWR(ord(\'n\'), 0, \'struct nvme_pt_command\');}' unless defined(&NVME_PASSTHROUGH_CMD);
    eval 'sub nvme_completion_is_error {
        my($cpl) = @_;
	    eval q((( &NVME_CQE_SC(($cpl)-> &flags) !=  &NVME_CQE_SC_SUCCESS) || ( &NVME_CQE_SCT(($cpl)-> &flags) !=  &NVME_CQE_SCT_GENERIC)));
    }' unless defined(&nvme_completion_is_error);
    if((defined(&_BYTE_ORDER) ? &_BYTE_ORDER : undef) != (defined(&_LITTLE_ENDIAN) ? &_LITTLE_ENDIAN : undef)) {
    }
# some #ifdef were dropped here -- fill in the blanks
    eval 'sub nvme_namespace_format_swapbytes {
        my($format) = @_;
	    eval q({ });
    }' unless defined(&nvme_namespace_format_swapbytes);
# some #ifdef were dropped here -- fill in the blanks
    eval 'sub nvme_identify_namespace_swapbytes {
        my($identify) = @_;
	    eval q({ });
    }' unless defined(&nvme_identify_namespace_swapbytes);
# some #ifdef were dropped here -- fill in the blanks
    eval 'sub nvme_identify_psd_swapbytes {
        my($psd) = @_;
	    eval q({ });
    }' unless defined(&nvme_identify_psd_swapbytes);
# some #ifdef were dropped here -- fill in the blanks
    eval 'sub nvme_identify_controller_swapbytes {
        my($identify) = @_;
	    eval q({ });
    }' unless defined(&nvme_identify_controller_swapbytes);
}
1;
