Make stopWaveform call interrupt callable (#5248)
Make stopWaveform call interrupt callable (#5248)

* Make stopWaveform call interrupt callable

Match the behavior of pre-2.4.2 PWM by allowing stopWaveform to be
called from an interrupt.

Fixes #5247

* Move to O2, save ~500 bytes of code

The actual runtime difference of -O2 vs -O3 is quite small, but -O3
takes ~500 more bytes of code (~300 more in IRAM, ~200 more in PMEM).

esp8266/Arduino,sticilface/Arduino,sticilface/Arduino,sticilface/Arduino,Lan-Hekary/Arduino,esp8266/Arduino,Lan-Hekary/Arduino,sticilface/Arduino,Lan-Hekary/Arduino,esp8266/Arduino,Lan-Hekary/Arduino,esp8266/Arduino,esp8266/Arduino,sticilface/Arduino,Lan-Hekary/Arduino