Compounds of general formula (I): wherein R1, R2, R3, R4, R5a, R5b X1, X2, Z and Y are as defined herein are positive modulators of the calcium-activated chloride channel (CaCC), TMEM16A. The compounds are useful for treating diseases and conditions affected by modulation of TMEM16A, particularly respiratory diseases and conditions.