As to the capability on the device, the capacity to scan for CSAM is very narrow and is very hard to repurpose.
The capacity to upload images to iCloud Photo Library on the other hand has been there for years.
At any time Apple could add some other kind of scanner if they want to, and there is no reason for it to use this mechanism. It would be terrible if they did but it has nothing to do with this.
Anyone with programming experience can tell you that if all they wanted to do was check arbitrary files against a list of hashes, they would be a simple mechanism to write.
There is no way that this mechanism helps them scan for other things. It isn’t even a step in that direction, let alone a baby step.