Yes, you need to set the drive mode for GPIO operation but for PWM operation all you need to do is set the direction to Output and configure the pin as PWM output.
Do you mean to say that drive mode setting is not needed for PWM.?
But as per datasheet (page no.12, under the heading-select PWM register), it says that the setting is needed.
CY8C9560A.pdf 736.5 K
To get pwn enabled and appear in the pin, you have to:
- the output pin must be 1 (writing 1 into the output register - 0x08 - 0x0f)
- the pwm must be enabled, too (writing into register 0x1a)
Table 8 on page 12 will help.