As mgb_phys stated you need to know the heat transfer in/out of the mass or the boundary worked performed on/by it. If the mass is compressible, you may also need to know the initial and final pressures as well.