Yes, the (x-M) or (M-x) is the radius of your shell, which you want to always be a positive number.

Volume of a shell =

Where the radius is the the positive distance between the curve and axis of rotation, the altitude is your function (or difference if there are two functions) and thickness is dx.