Linux OS/HW VM cooperation From what i've learned, the HW is responsible for setting the accessed and dirty bits in the PTE of a process, and the OS is responsible for turning them off.
My question is why?
The first part, i think is because only the HW is preforming the page table walk and it's a good opportunity for it to set them (because by doing the page walk or checking the tlb, it implies that a process wanted to access/write to a page).
Does the second part have something to do with the fact that the OS manages the page cache and all the paging to the disk go through it?
Why?  Because this design works pretty well and meets the requirements, and most alternative don't or would be more expensive or slower.  In particular, this division of responsibilities lets the system implement a suitable page replacement policy for virtual pages in a way that is relatively efficient.

When asking a "why is it done this way?", it's often helpful to try to imagine some concrete alternative way of doing it, and then analyze the advantages and disadvantages of the current method compared to that alternative.  You haven't listed a specific alternative, so it's hard to be a lot more specific.  But for instance if you tried to do it all in software (so the OS has all responsibility), without the hardware managing the accessed or dirty bits, that would be very difficult: the only methods I can think of for doing that are clunky and will cause many context switches and thus will slow down the system a lot.