Disclosed herein are compounds of formula (I): or pharmaceutically acceptable salts thereof, wherein X1, L, Rx, Ry, G, Z, A, m, n, and p are as defined in the specification. Compositions comprising such compounds and methods for treating conditions and disorders using such compounds and compositions are also disclosed.本文揭示式(I)化合物,或其醫藥學上可接受之鹽,其中X1、L、Rx、Ry、G、Z、A、m、n及p係如說明書中所定義。亦揭示包含該等化合物之組合物及使用該等化合物及組合物治療病狀及病症的方法。