]> git.proxmox.com Git - mirror_smartmontools-debian.git/blame - dev_ata_cmd_set.h
import smartmontools 7.0
[mirror_smartmontools-debian.git] / dev_ata_cmd_set.h
CommitLineData
2127e193
GI
1/*
2 * dev_ata_cmd_set.h
3 *
a86ec89e 4 * Home page of code is: http://www.smartmontools.org
2127e193 5 *
f9e10201 6 * Copyright (C) 2008 Christian Franke
2127e193 7 *
ff28b140 8 * SPDX-License-Identifier: GPL-2.0-or-later
2127e193
GI
9 */
10
11#ifndef DEV_ATA_CMD_SET_H
12#define DEV_ATA_CMD_SET_H
13
ff28b140 14#define DEV_ATA_CMD_SET_H_CVSID "$Id: dev_ata_cmd_set.h 4760 2018-08-19 18:45:53Z chrfranke $"
2127e193
GI
15
16#include "atacmds.h" // smart_command_set
17#include "dev_interface.h"
18
19/////////////////////////////////////////////////////////////////////////////
20// ata_device_with_command_set
21
22/// Adapter class to implement new ATA pass through old interface.
23
24class ata_device_with_command_set
25: public /*implements*/ ata_device
26{
27public:
28 /// ATA pass through mapped to ata_command_interface().
29 virtual bool ata_pass_through(const ata_cmd_in & in, ata_cmd_out & out);
30
31protected:
32 /// Old ATA interface called by ata_pass_through()
33 virtual int ata_command_interface(smart_command_set command, int select, char * data) = 0;
34
35 ata_device_with_command_set()
36 : smart_device(never_called) { }
37};
38
39#endif // DEV_ATA_CMD_SET_H