The DriverKit problems to develop multiple serial USB device

Hi, I am developing a DriverKit driver for a USB device which has multiple serial UARTs connected. Each UART will represent a cu.USBX port on Mac. My driver inherits IOUSBHostDevice class and it matches device ID well. Now, I am going to crate a new class inherits IOUserSerial to implement serial port. However, compiler said no new operator on base class. It seems the base OSObject class prevent to new the subclass as I did in IOKit driver. Since the similar IOUserSerial/IOUserUSBSerial examples are hard to find, I would like to ask if anyone can help me to solve this problem. Any feedback and clue is appreciated. Following are some snippets to show my situation.

My IOKit port driver inherits IORS232SerialStreamSync.

class KextSerial : public IORS232SerialStreamSync
{
    OSDeclareDefaultStructors( KextSerial )   ;    // Constructor & Destructor stuff
     :
}

My USB driver could create new KextSerials and initiate them as well.

KextSerial * newSerial = new KextSerial;
       
if( !newSerial->init(0, 0) ){
    goto FailExit;
}

However, in my DriverKit port driver inherits IOUserSerial.

class DextSerial : public IOUserSerial
{
      :
}

While I try to new the DextSerial as following.

DextSerial * newSerial = new DextSerial;

The compiler said "No matching function for call to 'operator new'"

Parallelly I have tried IOUserUSBSerial and OSObject, I got the same error message.

After reading this project. I think I have a misunderstanding of DriverKit. I should use IOService::Create instead of new operator. My subsequent question is how can I use IOService::Create without NewUserClient method? Do I must have an app to trigger the driver to instantiate a child service.

After reading this project. I think I have a misunderstanding of DriverKit. I should use IOService::Create instead of new operator. My subsequent question is how can I use IOService::Create without NewUserClient method? Do I must have an app to trigger the driver to instantiate a child service.

After reading this project. I think I have a misunderstanding of DriverKit. I should use IOService::Create instead of new operator. My subsequent question is how can I use IOService::Create without NewUserClient method? Do I must have an app to trigger the driver to instantiate a child service.

The DriverKit problems to develop multiple serial USB device
 
 
Q