tee: add sandbox driver
[oweals/u-boot.git] / include / serial.h
index 8b00f38280ff98d8cdfe664c9028f238211f5876..020cd392e888e2c0bdc2e28b025257e489db774a 100644 (file)
@@ -102,6 +102,11 @@ enum serial_stop {
 #define SERIAL_GET_STOP(config) \
        ((config & SERIAL_STOP_MASK) >> SERIAL_STOP_SHIFT)
 
+#define SERIAL_CONFIG(par, bits, stop) \
+                    (par << SERIAL_PAR_SHIFT | \
+                     bits << SERIAL_BITS_SHIFT | \
+                     stop << SERIAL_STOP_SHIFT)
+
 #define SERIAL_DEFAULT_CONFIG  SERIAL_PAR_NONE << SERIAL_PAR_SHIFT | \
                                SERIAL_8_BITS << SERIAL_BITS_SHIFT | \
                                SERIAL_ONE_STOP << SERIAL_STOP_SHIFT
@@ -182,16 +187,6 @@ struct dm_serial_ops {
         */
        int (*loop)(struct udevice *dev, int on);
 #endif
-       /**
-        * setparity() - Set up the parity
-        *
-        * Set up a new parity for this device.
-        *
-        * @dev: Device pointer
-        * @parity: parity to use
-        * @return 0 if OK, -ve on error
-        */
-       int (*setparity)(struct udevice *dev, enum serial_par parity);
 
        /**
         * setconfig() - Set up the uart configuration