/*
- * Copyright (c) 2005-2008 Zmanda Inc. All Rights Reserved.
- *
- * This library is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License version 2.1 as
- * published by the Free Software Foundation.
- *
- * This library is distributed in the hope that it will be useful, but
+ * Copyright (c) 2007,2008,2009 Zmanda, Inc. All Rights Reserved.
+ *
+ * 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 Lesser General Public
- * License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this library; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
- *
- * Contact information: Zmanda Inc., 465 S Mathlida Ave, Suite 300
- * Sunnyvale, CA 94086, USA, or: http://www.zmanda.com
+ * 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, write to the Free Software Foundation, Inc.,
+ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300
+ * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com
*/
#ifndef TAPE_DEVICE_H
/* characteristics of the device */
gboolean fsf, bsf, fsr, bsr, eom, bsf_after_eom, broken_gmt_online;
+ gboolean nonblocking_open, fsf_after_filemark;
int final_filemarks;
/* 0 if we opened with O_RDWR; error otherwise. */
extern DevicePropertyBase device_property_fsf;
#define PROPERTY_FSF (device_property_fsf.ID)
+extern DevicePropertyBase device_property_fsf_after_filemark;
+#define PROPERTY_FSF_AFTER_FILEMARK (device_property_fsf_after_filemark.ID)
+
extern DevicePropertyBase device_property_bsf;
#define PROPERTY_BSF (device_property_bsf.ID)
extern DevicePropertyBase device_property_bsf_after_eom;
#define PROPERTY_BSF_AFTER_EOM (device_property_bsf_after_eom.ID)
+/* Should the device be opened with O_NONBLOCK */
+extern DevicePropertyBase device_property_nonblocking_open;
+#define PROPERTY_NONBLOCKING_OPEN (device_property_nonblocking_open.ID)
+
/* How many filemarks to write at EOD? (Default is 2).
* This property is a G_TYPE_UINT, but can only really be set to 1 or 2. */
extern DevicePropertyBase device_property_final_filemarks;
/* useful callback for tape ops */
void tape_device_set_capabilities(TapeDevice *self,
gboolean fsf, PropertySurety fsf_surety, PropertySource fsf_source,
+ gboolean fsf_after_filemark, PropertySurety faf_surety, PropertySource faf_source,
gboolean bsf, PropertySurety bsf_surety, PropertySource bsf_source,
gboolean fsr, PropertySurety fsr_surety, PropertySource fsr_source,
gboolean bsr, PropertySurety bsr_surety, PropertySource bsr_source,