diff --git a/components/drivers/src/pipe.c b/components/drivers/src/pipe.c index 3f14e6a8372754db4abb36dbef668c34ea43cc7d..8a6c97aabfd1812dd61d935fdc4def5836b6a087 100644 --- a/components/drivers/src/pipe.c +++ b/components/drivers/src/pipe.c @@ -224,7 +224,7 @@ rt_err_t rt_pipe_init(struct rt_pipe_device *pipe, pipe->flag = flag; /* create pipe */ - pipe->parent.type = RT_Device_Class_Char; + pipe->parent.type = RT_Device_Class_Pipe; pipe->parent.init = RT_NULL; pipe->parent.open = RT_NULL; pipe->parent.close = RT_NULL; diff --git a/include/rtdef.h b/include/rtdef.h index a3d13bfc445e4c25b6338f81e3b4d78b0a5c2686..6caf713f45b5c7a138cfe4ca24d719a70dce4bcc 100644 --- a/include/rtdef.h +++ b/include/rtdef.h @@ -739,6 +739,7 @@ enum rt_device_class_type RT_Device_Class_SPIDevice, /**< SPI device */ RT_Device_Class_SDIO, /**< SDIO bus device */ RT_Device_Class_PM, /**< PM pseudo device */ + RT_Device_Class_Pipe, /**< Pipe device */ RT_Device_Class_Miscellaneous, /**< Miscellaneous device */ RT_Device_Class_Unknown /**< unknown device */ };