4 * Copyright (c) 2000 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
8 * Cherepanov Vitaliy <v.cherepanov@samsung.com>
9 * Nikita Kalyazin <n.kalyazin@samsung.com>
11 * Licensed under the Apache License, Version 2.0 (the "License");
12 * you may not use this file except in compliance with the License.
13 * You may obtain a copy of the License at
15 * http://www.apache.org/licenses/LICENSE-2.0
17 * Unless required by applicable law or agreed to in writing, software
18 * distributed under the License is distributed on an "AS IS" BASIS,
19 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20 * See the License for the specific language governing permissions and
21 * limitations under the License.
24 * - Samsung RnD Institute Russia
29 /* SWAP Device ioctl commands */
31 #include "ioctl_commands.h"
33 #include "da_protocol.h"
38 //send message to device
39 int ioctl_send_msg(struct msg_t *msg)
41 LOGI("write to device\n");
42 if (ioctl(manager.buf_fd, SWAP_DRIVER_MSG, msg) == -1) {
43 LOGE("write to device: %s\n", strerror(errno));