1 /* SPDX-License-Identifier: GPL-2.0+ */ 2 /* 3 * Copyright (c) 2022 Google, Inc. 4 * Written by Andrew Scull <ascull@google.com> 5 */ 6 7 #define LOG_CATEGORY UCLASS_FUZZING_ENGINE 8 9 #include <dm.h> 10 #include <fuzzing_engine.h> 11 dm_fuzzing_engine_get_input(struct udevice * dev,const uint8_t ** data,size_t * size)12int dm_fuzzing_engine_get_input(struct udevice *dev, 13 const uint8_t **data, 14 size_t *size) 15 { 16 const struct dm_fuzzing_engine_ops *ops = device_get_ops(dev); 17 18 if (!ops->get_input) 19 return -ENOSYS; 20 21 return ops->get_input(dev, data, size); 22 } 23 24 UCLASS_DRIVER(fuzzing_engine) = { 25 .name = "fuzzing_engine", 26 .id = UCLASS_FUZZING_ENGINE, 27 }; 28