Friction is always tangent to the position of the particle. Therefore, the friction torque on the particle is equal to the product of the friction force and the distance from the particle to the O point, that is, dM = rXdF.
The r of each point on a ring centered on point o is equal. So when choosing an infinitesimal, choose this ring as the infinitesimal. So all you have to do is integrate R, which has the advantage of avoiding double integration.
This is a trick.