HDFC credit card holders can change the ATM pin through the following ways

Online: 

You can login to your net banking and go to the credit card section to change the ATM pin. You will receive an OTP to your registered mobile number for verification. After entering the OTP, the ATM pin will be changed. 

At ATM

The new ATM pin can be generated only at HDFC ATMs. You will have to enter the OTP to create a new pin. After the change has been made, you will receive a confirmation message on your registered mobile number.